How to mount existing letsencrypt directory? · Issue #2781 · NginxProxyManager/nginx

您所在的位置:网站首页 nginx-proxy How to mount existing letsencrypt directory? · Issue #2781 · NginxProxyManager/nginx

How to mount existing letsencrypt directory? · Issue #2781 · NginxProxyManager/nginx

2023-04-04 19:34| 来源: 网络整理| 查看: 265

For my required setup, I currently have all my letsencrypt certificates stored on an NFS drive and mount them to /etc/letsencrypt on each required host. So I tried to do the same with the Nginx Proxy Manager and mounted the existing path with /etc/letsencrypt:/etc/letsencrypt instead of ./letsencrypt:/etc/letsencrypt as given in the default configuration:

version: '3.8' services: app: image: 'jc21/nginx-proxy-manager:2.9.22' restart: unless-stopped ports: # These ports are in format : - '80:80' # Public HTTP Port - '443:443' # Public HTTPS Port - '81:81' # Admin Web Port # Add any other Stream port you want to expose # - '21:21' # FTP environment: # Unix user and group IDs, optional PUID: 1000 PGID: 1000 # Mysql/Maria connection parameters: DB_MYSQL_HOST: "db" DB_MYSQL_PORT: 3306 DB_MYSQL_USER: "npm" DB_MYSQL_PASSWORD: "npm" DB_MYSQL_NAME: "npm" # Uncomment this if IPv6 is not enabled on your host DISABLE_IPV6: 'true' volumes: - ./data:/data - /etc/letsencrypt:/etc/letsencrypt depends_on: - db db: image: 'jc21/mariadb-aria:latest' restart: unless-stopped environment: MYSQL_ROOT_PASSWORD: 'npm' MYSQL_DATABASE: 'npm' MYSQL_USER: 'npm' MYSQL_PASSWORD: 'npm' volumes: - ./data/mysql:/var/lib/mysql

This seems to work fine. I can see the directory on my local host:

root@npm:/# ls /etc/letsencrypt accounts archive cli.ini csr keys live options-ssl-apache.conf renewal renewal-hooks

And I can see in the docker container that the container can access them as well:

root@npm:/# docker exec -it a /bin/bash [root@docker-a88aa14b1b11:/app]# ls /etc/letsencrypt accounts archive cli.ini csr keys live options-ssl-apache.conf renewal renewal-hooks

However, I am not able to access those certificates which are already existing when I use the web GUI. The Nginx Proxy Manager seems to have no information about those certificates and I can only create new ones.

How can I make the certificates known to NPM? Did I mount an incorrect path structure?



【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3