Registry of customized packs for Nomad Pack.
- nomad-pack >= 0.4.2
To configure this registry for using its packs, run:
nomad-pack registry add <name> github.com/flaudisio/nomad-pack-registry [--ref <git ref>]Example:
# Using the latest version
nomad-pack registry add flaudisio github.com/flaudisio/nomad-pack-registry
# Using specific version
nomad-pack registry add flaudisio github.com/flaudisio/nomad-pack-registry --ref v0.10.0Multiple registry versions can be added. To deploy specific pack versions, use the --ref argument
(see below for examples).
-
(Recommended) Create a variables file for each deployment.
For example, to deploy the whoami application using the webapp pack:# whoami/variables.hcl job_name = "whoami" image_name = "traefik/whoami" image_tag = "latest" port = 80
-
Plan the deployment to review the expected changes:
nomad-pack plan webapp --name whoami -f whoami/variables.hcl --registry flaudisio --verbose # Using specific pack version nomad-pack plan webapp --name whoami -f whoami/variables.hcl --registry flaudisio --ref v0.10.0 --verbose -
Run the deployment:
nomad-pack run webapp --name whoami -f whoami/variables.hcl --registry flaudisio # Using specific pack version nomad-pack run webapp --name whoami -f whoami/variables.hcl --registry flaudisio --ref v0.10.0
See also the examples folder for sample usage.
-
Check the existing deployments for the target pack:
nomad-pack status webapp nomad-pack status webapp --name whoami
-
Stop/destroy the deployment:
# In two steps: stop then remove the job nomad-pack stop webapp --name whoami -f whoami/variables.hcl --registry flaudisio nomad-pack stop webapp --name whoami -f whoami/variables.hcl --purge --registry flaudisio # Or use 'destroy' to stop and destroy in a single step nomad-pack destroy webapp --name whoami -f whoami/variables.hcl --registry flaudisio
If the pack was deployed using a specific version, make sure to also use the version in the stop/destroy commands:
nomad-pack stop webapp --name whoami -f whoami/variables.hcl --registry flaudisio --ref v0.10.0 nomad-pack stop webapp --name whoami -f whoami/variables.hcl --purge --registry flaudisio --ref v0.10.0 nomad-pack destroy webapp --name whoami -f whoami/variables.hcl --registry flaudisio --ref v0.10.0
-
Check the configured registries:
nomad-pack registry list
-
Remove the packs:
# Remove all pack versions nomad-pack registry delete flaudisio # Remove only the latest pack versions nomad-pack registry delete flaudisio --ref latest # Remove specific pack versions nomad-pack registry delete flaudisio --ref v0.3.0 nomad-pack registry delete flaudisio --ref v0.10.0
See the test folder for details.
MIT.