From ac8d2f62357a5284fe15ae531a773e8b99f2fa08 Mon Sep 17 00:00:00 2001 From: Armon Dadgar Date: Sat, 26 Sep 2015 18:26:51 -0700 Subject: [PATCH] website: lowercase examples of dynamic ports --- command/init.go | 2 +- website/source/docs/jobspec/index.html.md | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/command/init.go b/command/init.go index da4d2b515..ee0bd99ad 100644 --- a/command/init.go +++ b/command/init.go @@ -116,7 +116,7 @@ job "example" { memory = 256 # 256MB network { mbits = 10 - dynamic_ports = ["REDIS"] + dynamic_ports = ["redis"] } } } diff --git a/website/source/docs/jobspec/index.html.md b/website/source/docs/jobspec/index.html.md index aa8809c7e..aa1aba33b 100644 --- a/website/source/docs/jobspec/index.html.md +++ b/website/source/docs/jobspec/index.html.md @@ -8,8 +8,8 @@ description: |- # Job Specification -Jobs can be specified either in [HCL](https://github.com/hashicorp/hcl) or JSON. -HCL is meant to strike a balance between human readable and editable, as well +Jobs can be specified either in [HCL](https://github.com/hashicorp/hcl) or JSON. +HCL is meant to strike a balance between human readable and editable, as well as being machine-friendly. For machine-friendliness, Nomad can also read JSON configurations. In general, we recommend @@ -51,8 +51,8 @@ job "my-service" { network { mbits = 100 dynamic_ports = [ - "HTTP", - "HTTPS", + "http", + "https", ] } } @@ -187,7 +187,7 @@ The `resources` object supports the following keys: The `network` object supports the following keys: -* `dynamic_ports` - List of port labels which may contain uppercase letters, +* `dynamic_ports` - List of port labels which may contain letters, numbers and underscores (`^[a-zA-Z0-9_]+$`). Each label will be assigned a dynamic port when the task starts. Ports are passed to the task environment as `NOMAD_PORT_{LABEL}`. Drivers may infer additional semantics from the label.