Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Container status is unhealthy running alongside Nginx Proxy Manager #1

Open
rubylaser opened this issue Mar 18, 2022 · 0 comments
Open

Comments

@rubylaser
Copy link

rubylaser commented Mar 18, 2022

I have been using Nginx Proxy Manager for a months and it's been working great (along with about 20 other Docker containers). I wanted to setup step-ca to provide ssl certs to my internal hosts. I can't figure this out, so I'm sure that must be using this container incorrectly, because it shows up as Unhealthy status. It's trying to use port 443 which conflicts with NPM. I have this all setup in docker compose like this.

    nginx-proxy-manager:
        hostname: nginx-proxy-manager
        container_name: nginx-proxy-manager
        ports:
            # Public HTTP Port:
            - '80:80'
            # Public HTTPS Port:
            - '443:443'
            # Admin Web Port:
            - '1881:81'
        environment:
            # These are the settings to access your db
            DB_MYSQL_HOST: "db"
            DB_MYSQL_PORT: 3306
            DB_MYSQL_USER: "npm"
            DB_MYSQL_PASSWORD: "npm"
            DB_MYSQL_NAME: "npm"
            DISABLE_IPV6: 'true'
        volumes:
            - /docker/containers/nginx-proxy-manager/data:/data
            - /docker/containers/nginx-proxy-manager/letsencrypt:/etc/letsencrypt
        depends_on:
            - db
        restart: unless-stopped
        image: 'jc21/nginx-proxy-manager:latest'

    db:
        hostname: db
        container_name: db
        environment:
            MYSQL_ROOT_PASSWORD: 'npm'
            MYSQL_DATABASE: 'npm'
            MYSQL_USER: 'npm'
            MYSQL_PASSWORD: 'npm'
        volumes:
            - /docker/containers/nginx-proxy-manager/data/mysql:/var/lib/mysql
        image: 'jc21/mariadb-aria:latest'
        restart: unless-stopped
    stepca:
        container_name: step-ca
        networks:
          default:
            aliases:
              - ca.lab
        image: nginxproxymanager/testca

I have created an internal DNS entry that resolves properly to ca.lab. Here's what the log shows. I don't see

docker logs -f step-ca
badger 2022/03/18 00:10:44 INFO: All 0 tables opened in 0s
2022/03/18 00:10:44 Serving HTTPS on :443 ...

I'm also unclear, even if the port conflict is resolved, exactly how to use this alongside NPM. There is no /home/step directory being created on the host either, although I can see them in the running container.

root@frontend:~# docker exec -it step-ca /bin/bash
bash-5.1$ cd certs/
bash-5.1$ ls
intermediate_ca.crt  root_ca.crt

I guess I'm not exactly sure how I'm supposed to use this to generate certs for my other internal Docker containers. Any help is greatly appreciated. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant