Skip to content

Commit

Permalink
Merge pull request #237 from Nordix/arpest_update_envs
Browse files Browse the repository at this point in the history
Align env vars
  • Loading branch information
denis-tingaikin authored May 14, 2024
2 parents 816db5b + 0afa01c commit bfa2966
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 3 deletions.
22 changes: 21 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,26 @@ You can build the docker container by running:
docker build .
```

# Usage

## Environment config

* `NSM_NAME` - Name of vL3 Server (default: "docker-vl3-server")
* `NSM_REQUEST_TIMEOUT` - timeout to request NSE (default: "15s")
* `NSM_CONNECT_TO` - url to connect to (default: "tcp://k8s.nsm")
* `NSM_MAX_TOKEN_LIFETIME` - maximum lifetime of tokens (default: "10m")
* `NSM_REGISTRY_CLIENT_POLICIES` - paths to files and directories that contain registry client policies (default: "etc/nsm/opa/common/.*.rego,etc/nsm/opa/registry/.*.rego,etc/nsm/opa/client/.*.rego")
* `NSM_SERVICE_NAMES` - Name of providing service (default: "docker-vl3")
* `NSM_REGISTER_SERVICE` - if true then registers network service on startup (default: "true")
* `NSM_REGISTER_AS_URL` - Endpoint URL
* `NSM_LABELS` - Endpoint labels
* `NSM_TUNNEL_IP` - IP to use for tunnels
* `NSM_VL3_PREFIX` - vl3 prefix (default: "169.254.0.0/16")
* `NSM_INTERFACE_NAME` - Name of the nsm network interface (default: "nsm")
* `NSM_FEDERATES_WITH` - Name of the federated domain (default: "k8s.nsm")
* `NSM_TRUST_DOMAIN` - Name of the trust domain (default: "docker.nsm")
* `NSM_LOG_LEVEL` - Log level (default: "INFO")

# Testing

## Testing Docker container
Expand Down Expand Up @@ -72,4 +92,4 @@ docker run --privileged -e DLV_LISTEN_FORWARDER=:50000 -p 40000:40000 -p 50000:5
```

Please note, the tests **start** the cmd, so until you connect to port 40000 with your debugger and walk the tests
through to the point of running cmd, you will not be able to attach a debugger on port 50000 to the cmd.
through to the point of running cmd, you will not be able to attach a debugger on port 50000 to the cmd.
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,8 @@ type Config struct {
RegisterAsURL url.URL `default:"" desc:"Endpoint URL" split_words:"true"`
Labels map[string]string `default:"" desc:"Endpoint labels"`
TunnelIP net.IP `desc:"IP to use for tunnels" split_words:"true"`
Vl3Prefix string `default:"169.254.0.0/16" desc:"vl3 prefix"`
InterfaceName string `default:"nsm" desc:"Name of the nsm network interface"`
Vl3Prefix string `default:"169.254.0.0/16" desc:"vl3 prefix" split_words:"true"`
InterfaceName string `default:"nsm" desc:"Name of the nsm network interface" split_words:"true"`
FederatesWith string `default:"k8s.nsm" desc:"Name of the federated domain" split_words:"true"`
TrustDomain string `default:"docker.nsm" desc:"Name of the trust domain" split_words:"true"`
LogLevel string `default:"INFO" desc:"Log level" split_words:"true"`
Expand Down

0 comments on commit bfa2966

Please sign in to comment.