From your Teleport server Docker container logs, here's a diagnosis of what's preventing you from accessing Teleport and its UI:
The most critical errors in your logs point to TLS certificate verification failures. This means the Teleport components are unable to trust each other's certificates, which is essential for secure communication.
You see these repeated errors:
WARN [MXTLS:1] Handshake failed src_addr:127.0.0.1:45258 dst_addr:127.0.0.1:3025 error:[tls: failed to verify certificate: x509: certificate signed by unknown authority] multiplexer/tls.go:152ERRO [PROC:1] Failed to establish connection to cluster. pid:7.1 identity:Instance error:[...remote error: tls: unknown certificate authority"]
This indicates that the Teleport service running inside the container cannot establish a secure connection to its own Auth Server (listening on 0.0.0.0:3025) because it doesn't recognize the certificate authority that signed the Auth Server's certificate.
-
Self-Signed Certificates (and their handling):
WARN [PROC:1] No TLS Keys provided, using self-signed certificate. pid:7.1 service/service.go:6577- Teleport is starting with self-signed certificates. While this is common for initial setups or development environments, it means that components need to be explicitly configured to trust these self-signed certificates. If they are not, you'll get the "unknown certificate authority" error.
- Possible issue: The client (likely the Teleport proxy/node trying to connect to the Auth service, or your browser trying to access the UI) isn't configured to trust the self-signed certificate generated by your Teleport Auth server.
-
Auth Server Address and
proxy_protocolWarning:WARN [AUTH:1] 'proxy_protocol' unspecified. Starting Auth service with external PROXY protocol support, but IP pinned connection affected by PROXY headers will not be allowed. Set 'proxy_protocol: on' in 'auth_service' config if Auth service runs behind L4 load balancer with enabled PROXY protocol, or set 'proxy_protocol: off' otherwise pid:7.1 service/service.go:2444WARN [AUTH:1] Configuration setting auth_service/advertise_ip is not set, using inferred address pid:7.1 address:172.18.0.6:3025 service/service.go:2527- The
proxy_protocolwarning suggests that if you have a load balancer in front of Teleport, it might be interfering with how IP addresses are seen by the Auth service. This is less likely to be the root cause of the "unknown certificate authority" error, but it's something to address for proper network setup, especially if you plan to use a load balancer. - The
advertise_ipwarning indicates Teleport is inferring its own IP address (172.18.0.6:3025). In a Docker environment, this is usually the container's internal IP. While not directly an error, if your clients are trying to connect via a different external IP/hostname, this could indirectly contribute to certificate issues if the certificate was issued for a different hostname.
-
PostgreSQL Serialization Error (Minor/Transient):
DEBU [PGBK] Operation failed due to conflicts, retrying quickly. attempt:1 error:[Original Error: *pgconn.PgError ERROR: could not serialize access due to read/write dependencies among transactions (SQLSTATE 40001)]- This is a
DEBUGlevel message and indicates a transient database transaction conflict with PostgreSQL, which Teleport handles by retrying. This is unlikely to be the primary cause of your access issues.
Here's what you should check and try:
-
Teleport Configuration (
teleport.yaml):- Certificate Paths: Ensure that your
teleport.yamlfile explicitly defines paths fortls_key_fileandtls_cert_filewithin theauth_serviceandproxy_servicesections, and that these paths are correctly mounted into your Docker container. If you're using self-signed certificates, ensure they are generated correctly and placed where Teleport expects them. - Cluster Name: Verify that the
cluster_nameinteleport.yamlmatches what you expect (e.g.,infra.zingastay.com). auth_serviceandproxy_servicelisten_addrandweb_listen_addr:- Make sure
listen_addrforauth_serviceis set to0.0.0.0:3025(which your logs show it's listening on). - Ensure your
proxy_servicehasweb_listen_addrconfigured, typically0.0.0.0:443or0.0.0.0:3080(or whatever port you've exposed for the UI). - If
proxy_serviceis disabled, you won't have a web UI. Make sure it's enabled in yourteleport.yaml.
- Make sure
- Certificate Paths: Ensure that your
-
Trusting Certificates:
- If using self-signed certs (common for quick starts): You'll need to configure your client (e.g., your web browser,
tshclient) to trust the CA certificate generated by Teleport.- For the UI: When you first try to access the Teleport UI in your browser, you might get a "Your connection is not private" warning. You'll need to proceed past this warning or import the Teleport CA certificate into your browser's trust store.
- For
tsh(Teleport CLI): You'll often need to runtsh login --proxy=<proxy-address> --insecureinitially if you haven't set up proper certificate trust, or ensure yourtshclient is configured to use the correct CA.
- For production: You'll want to use certificates signed by a trusted Certificate Authority (CA), like Let's Encrypt, and configure Teleport to use those.
- If using self-signed certs (common for quick starts): You'll need to configure your client (e.g., your web browser,
-
Port Mapping in
docker-compose.yaml:- Confirm that your
docker-compose.yamlcorrectly maps the necessary Teleport ports from the container to your host.- Auth Service:
3025(for internal communication andtshdirect connections) - Proxy Service (Web UI):
3080(HTTPS UI andtshproxy connections) and potentially3023(SSH proxy).
- Auth Service:
- Example:
services: teleport-server: # ... other configs ports: - "3025:3025" # Auth service - "3080:3080" # Web UI and HTTPS proxy - "3023:3023" # SSH proxy # ... other ports like 3024 (auth/node) if needed
- Confirm that your
-
Network Connectivity:
- From the host machine, can you
curlthe Teleport UI port?curl -k https://localhost:3080(replacelocalhostand3080with your actual host IP and Teleport UI port). The-kignores certificate errors, which helps confirm basic connectivity. - Ensure no firewall rules (either on the host or within your cloud provider/VM) are blocking access to the exposed Teleport ports.
- From the host machine, can you
-
Review
teleport.yamlagain thoroughly. Theteleport.yamldefines how your Teleport instance behaves. Small misconfigurations, especially aroundadvertise_ipandproxy_protocolin conjunction withauth_servervs.proxy_servercan lead to these kinds of issues.
By addressing the TLS certificate verification errors and ensuring your teleport.yaml and Docker Compose port mappings are correct, you should be able to resolve the access issues.