Roblox / nomad-driver-containerd

Nomad task driver for launching containers using containerd.
Other
220 stars 35 forks source link

Forward Redis port 6379 #150

Closed cilex-ft closed 1 year ago

cilex-ft commented 1 year ago

I'm currently evaluating nomad to replace our lxd stack.

The standard docker driver works well, but I can't figure out what it brings; so I'd like to get rid of it, and use containerd directly instead - I followed your instructions and hello.nomad runs without issues.

However I'm testing your redis.nomad now and I can't find out how to forward ports. Redis runs and listens on its internal port 6379, but I can't forward this port to the host (dynamic or static port). I tried many combinations without success - host_network = true forwards to port 6379.

Do you please have a working example? Or, do I really have to install CNI plugin to get a working bridge, and have a config file in /opt/cni/config (nomad.hcl / client / cni_config_dir)? Where can I find such a config file?

shishir-a412ed commented 1 year ago

@cilex-ft This is not specific to containerd-driver. Port mapping is handled by nomad, please check nomad docs on how to map static and dynamic ports into the container.