Artifact behavior

28 views
Skip to first unread message

Justin DynamicD

unread,
Nov 11, 2017, 9:38:42 PM11/11/17
to Nomad
Is there a link or live-in that has more details on artifacts and how they actually function?

For example: if a container moves, is drained, are the artifacts cleaned up? What happens if the source updates, does the artifact great periodically checked? What about group of taking that all need the same artifact, what's the danger (if any) of multiple declaration?

Rather than a long dialog, are these details posted somewhere so I can understand behavior better?

Justin DynamicD

unread,
Nov 12, 2017, 1:05:16 AM11/12/17
to Nomad
Checking up and rereading this I realize swipe has mangled a few things.  So to re-clarify:

Is there a site I can go to that reveals the details of how the artifact stanza works?  the main page is decent about explaining the basics, but there are more details I'd like to read up on rather than spend a ton of time on some trial and error attempts.

Most pressing questions:

 - It looks as if artifacts are declared only at the task level.  What if a job of multiple containers effectively call for the copying of the same artifact?  will they each copy to the local host?  will they overwrite/conflict with each other?  Should they be kept unique? 
 - Can artifacts leverage docker data volumes named volumes?
 - as containers can "move" between hosts for various reasons, does nomad cleanup old artifacts (Assuming it dumps locally on the host)?

It's a complex series of behavior questions, so I don't know that harassing groups is the best route ... so if anyone could point me to better documentation I'd appreciate it.

Alex Dadgar

unread,
Nov 13, 2017, 1:26:28 PM11/13/17
to Justin DynamicD, Nomad
Hey Justin,

The artifact stanza is rather simple. Before a task starts up for the first time the artifact is downloaded using go-getter. There is a command version of that library such that you can play with it and see its behavior if you are so inclined. The artifact is downloaded into the tasks directory which is cleaned up after the allocation is terminal. There is no interaction between artifacts on one host and those on the other and further it is unrelated to the docker driver.

You can download to a directory and then use the docker driver to bind that folder into the container but those are separated.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/hashicorp/nomad/issues
IRC: #nomad-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Nomad" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nomad-tool+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nomad-tool/38453750-6311-4924-b6cf-0a8bffc7caa8%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Thanks,
Alex

Justin DynamicD

unread,
Nov 13, 2017, 6:02:54 PM11/13/17
to Nomad
Thanks for the fast answer.

So what happens if multiple tasks require the same artifact (for example multiple tasks in a group)?  do I have to ensure each one goes to a unique folder so nothing gets accidentally cleaned up? is the path relative to the container name so it's clean?  Does it depend on how I syntax the artifact folder?
To unsubscribe from this group and stop receiving emails from it, send an email to nomad-tool+...@googlegroups.com.



--
Thanks,
Alex

Alex Dadgar

unread,
Nov 13, 2017, 6:45:40 PM11/13/17
to Justin DynamicD, Nomad
Hey Justin,

It will be downloaded by each task independently. The default destination is the task's local/ folder, so there will be no issue between the task's artifacts.

To unsubscribe from this group and stop receiving emails from it, send an email to nomad-tool+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nomad-tool/f51dad5d-5e45-46fa-9495-cb9b0a56c410%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Thanks,
Alex
Reply all
Reply to author
Forward
0 new messages