Few improvement to run GDK in the cloud
What does this Merge Request do?
This is a more opinionated MR.
Use listen address instead of hostname in some places because the hostname
address might be bound to an IP that the machine in the cloud might not have
direct access to. So the cloud computer will set 0.0.0.0
as listen address,
while the hostname is some domain that will resolve to a public IP on the
interwebs.
Closes #978 (closed)
gdk.yml
The gdk.yml
I was using for this:
hostname: one.gdk.iotcl.net
listen_address: 0.0.0.0
port: 443
https:
enabled: true
nginx:
enabled: true
http:
enabled: true
port: 80
ssl:
certificate: one.gdk.iotcl.net.pem
key: one.gdk.iotcl.net-key.pem
geo:
enabled: true
node_name: one.gdk.iotcl.net
sshd:
enabled: true
listen_port: 2222
sshd & nginx
I'm running nginx
and sshd
without sudo
. I've achieved this by running:
sudo setcap CAP_NET_BIND_SERVICE=+eip /usr/sbin/nginx
sudo setcap cap_setuid,cap_setgid,cap_net_bind_service+eip /usr/sbin/sshd
TLS
I'm using a self-signed cert generated on my local machine with mkcert
and scp
'd it over to the GCP VM.
Merge Request checklist
-
Tests added for new functionality. If not, please raise Issue to follow-up. -
This change is backward compatible. If not, please include steps to communicate to our users. -
Documentation added/updated, if needed. -
gdk doctor
test added, if needed.
Edited by Toon Claes