I really don’t know what’s happening here. It seems like the s3 container dies instantly, so that the registry container follows with code 255 (like the s3 container), so that HAProxy won’t start, because the hostnames could not be resolved (because the containers are no longer there) and the cert container can’t connect to port 80 because of HAProxy not serveing anything at all.
s3 dies → registry dies → HAProxy won’t start → nothing
Why is s3 exiting? Where can I find the right logs?
There is no problem with the firewall. Firewall is widely open to anyone. httpd container was able to server 80 without any problems.
Running a VPS on STRATO.de with 1vCore 2GB RAM and Ubuntu 18.04
Domain is a sub-domain: openbalena.linus-h.de
with A and AAAA record. Subdomains of that are api, registry, s3 and vpn. All with CNAME to openbalena.linus-h.de.
Output from $ ~/open-balena/scripts/compose up
root@h2902577:~/open-balena# ./scripts/compose up
Starting openbalena_s3_1 ... done
Starting openbalena_cert-provider_1 ... done
Starting openbalena_db_1 ... done
Starting openbalena_redis_1 ... done
Starting openbalena_api_1 ... done
Starting openbalena_registry_1 ... done
Starting openbalena_vpn_1 ... done
Starting openbalena_haproxy_1 ... done
Attaching to openbalena_s3_1, openbalena_cert-provider_1, openbalena_db_1, openbalena_redis_1, openbalena_api_1, openbalena_registry_1, openbalena_vpn_1, openbalena_haproxy_1
s3_1 | Systemd init system enabled.
cert-provider_1 | [Info] VALIDATION not set. Using default: http-01
cert-provider_1 | [Info] Waiting for api.openbalena.linus-h.de to be available via HTTP...
cert-provider_1 | [Info] (1/3) Connecting...
cert-provider_1 | [Info] (1/3) Failed. Retrying in 5 seconds...
cert-provider_1 | [Info] (2/3) Connecting...
cert-provider_1 | [Info] (2/3) Failed. Retrying in 5 seconds...
db_1 | 2020-09-01 18:00:44.497 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432
db_1 | 2020-09-01 18:00:44.497 UTC [1] LOG: listening on IPv6 address "::", port 5432
db_1 | 2020-09-01 18:00:44.497 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
db_1 | 2020-09-01 18:00:44.533 UTC [21] LOG: database system was shut down at 2020-09-01 17:56:47 UTC
db_1 | 2020-09-01 18:00:44.588 UTC [1] LOG: database system is ready to accept connections
redis_1 | 1:C 01 Sep 2020 18:00:44.790 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
redis_1 | 1:C 01 Sep 2020 18:00:44.790 # Redis version=6.0.6, bits=64, commit=00000000, modified=0, pid=1, just started
redis_1 | 1:C 01 Sep 2020 18:00:44.790 # Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf
redis_1 | 1:M 01 Sep 2020 18:00:44.793 * Running mode=standalone, port=6379.
redis_1 | 1:M 01 Sep 2020 18:00:44.793 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
redis_1 | 1:M 01 Sep 2020 18:00:44.793 # Server initialized
redis_1 | 1:M 01 Sep 2020 18:00:44.797 * Loading RDB produced by version 6.0.6
redis_1 | 1:M 01 Sep 2020 18:00:44.797 * RDB age 237 seconds
redis_1 | 1:M 01 Sep 2020 18:00:44.797 * RDB memory usage when created 0.77 Mb
redis_1 | 1:M 01 Sep 2020 18:00:44.797 * DB loaded from disk: 0.004 seconds
redis_1 | 1:M 01 Sep 2020 18:00:44.797 * Ready to accept connections
api_1 | Systemd init system enabled.
registry_1 | Systemd init system enabled.
openbalena_s3_1 exited with code 255
vpn_1 | Systemd init system enabled.
haproxy_1 | Building certificate from environment variables...
openbalena_registry_1 exited with code 255
haproxy_1 | Setting up watches. Beware: since -r was given, this may take a while!
haproxy_1 | Watches established.
haproxy_1 | [ALERT] 244/180048 (15) : parsing [/usr/local/etc/haproxy/haproxy.cfg:73] : 'server balena_registry_1' : could not resolve address 'registry'.
haproxy_1 | [ALERT] 244/180048 (15) : parsing [/usr/local/etc/haproxy/haproxy.cfg:85] : 'server balena_s3_1' : could not resolve address 's3'.
haproxy_1 | [ALERT] 244/180048 (15) : Failed to initialize server(s) addr.
cert-provider_1 | [Info] (3/3) Connecting...
cert-provider_1 | [Info] (3/3) Failed!
cert-provider_1 | [Info] Unable to access api.openbalena.linus-h.de on port 80. This is needed for certificate validation. Retrying in 30 seconds...
cert-provider_1 | [Info] Waiting for api.openbalena.linus-h.de to be available via HTTP...
cert-provider_1 | [Info] (1/3) Connecting...
cert-provider_1 | [Info] (1/3) Failed. Retrying in 5 seconds...
cert-provider_1 | [Info] (2/3) Connecting...
cert-provider_1 | [Info] (2/3) Failed. Retrying in 5 seconds...
cert-provider_1 | [Info] (3/3) Connecting...
cert-provider_1 | [Info] (3/3) Failed!
cert-provider_1 | [Info] Unable to access api.openbalena.linus-h.de on port 80. This is needed for certificate validation. Retrying in 30 seconds...
docker-compose.yml
is based on
$ ~/open-balena/scripts/quickstart -U XXXXXXX@YYY.de -P 'XXXXXXXXXXXX' -d openbalena.linus-h.de -c