lhaig / example-pack
Published by Lance Haig | View Source
0 stars
- Description
- Example Nomad Pack
- License
- MPL-2.0
- Tags
-
#example #pack
- Repository URL
- https://github.com/open-wander/example-pack
- Versions
- Select a version to see its documentation and run command.
- Quick Run (v0.0.1)
-
ramble pack run lhaig/example-pack@v0.0.1 - metadata.hcl
-
app { url = "https://github.com/open-wander/example-pack" } pack { name = "hello_pack" description = "A simple Nomad job that runs as a service and can be accessed via HTTP." version = "0.0.1" } # Optional dependency information. This block can be repeated. # dependency "demo_dep" { # alias = "demo_dep" # source = "git://source.git/packs/demo_dep" # } # Declared dependencies will be downloaded from their source # using "nomad-pack vendor deps" and added to ./deps directory. # Dependencies in active development can by symlinked in # the ./deps directory # Example dependency source values: # - "git::https://github.com/org-name/repo-name.git//packs/demo_dep" # - "git@github.com:org-name/repo-name.git/packs/demo_dep" - README
-
# hello_pack This pack is a simple Nomad job that runs as a service and can be accessed via HTTP. ## Pack Usage ### Changing the Message To change the message this server responds with, change the "message" variable when running the pack. ```bash nomad-pack run hello_pack --var message="Hola Mundo!" ``` This tells Nomad Pack to tweak the `MESSAGE` environment variable that the service reads from. ## Variables | Variable | Description | Type | Default | |Str|Str|Str|Str| |---|---|---|---| | `message` | The message your application will respond with | string | `"Hello World!"` | | `count` | The number of app instances to deploy | number | `2` | | `job_name` | The name to use as the job name which overrides using the pack name | string | `""` (Pack Name) | | `datacenters` | A list of datacenters in the region which are eligible for task placement | list(string) | `["*"]` | | `region` | The region where jobs will be deployed | string | `""` | | `register_service` | If you want to register a Nomad service for the job | bool | `true` | | `service_name` | The service name for the hello_pack application | string | `"webapp"` | | `service_tags` | The service tags for the hello_pack application | list(string) | `["urlprefix-/", "traefik.enable=true", ...]` | [pack-registry]: https://rmbl.openwander.org/