How to Migrate from an Existing NGINX Proxy Manager Deployment and Keep Configuration

To migrate from an existing NGINX Proxy Manager installation to a version which provides also open-appsec integration here's some guidance:

This is only relevant if you want to keep your existing NGINX Proxy Manager configuration, otherwise it is suggested to start fresh with the deployment instructions shown on these pages:

Deploy NGINX Proxy Manager with open-appsec managed from NPM WebUI Deploy NGINX Proxy Manager with open-appsec managed from central WebUI (SaaS)

  • Change into your existing folder that contains the docker-compose.yml file and all related files and folders for your current NGINX Proxy Manager deployment.

  • Stop your current deployment with docker-compose down in the folder that contains your docker-compose.yaml file used for the NGINX Proxy Manager deployment.

  • Make a full backup of your existing folder that contains the NGINX Proxy Manager docker compose environment, including any mounted volumes like ./data and ./letsencrypt, etc. to a safe location. This will allow you to bring it up with docker-compose up later exactly as it was before the migration, if required for some reason.

  • Rename the original docker-compose.yml file (so you will still have it as a backup):

mv ./docker-compose.yml ./docker-compose.npm.orig.yml

Please carefully read the important considerations below!

Only then follow the regular instructions for the deployment:

Deploy NGINX Proxy Manager with open-appsec managed from NPM WebUI

Important considerations:

  • Your existing NGINX Proxy Manager (and Let's Encrypt) configuration will still be available also once migrated to the open-appsec enhanced NGINX Proxy Manager deployment as long as it still resides in the local ./data and ./letssencrypt folders.

  • If you did any important changes to the original docker-compose.yml file from the NGINX Proxy Manager project: Once you downloaded the docker-compose.yaml file for deployment of NGINX Proxy Manager with open-appsec, make sure to apply these changes also to this docker-compose.yaml file. You can compare the new docker-compose.yaml with the renamed docker-compose.orig.yaml file of you previous deployment of only NGINX Proxy Manager. Note that for the open-appsec integration a combination of a docker-compose.yaml file with a .env file is being used, as this allows for easier customization of commonly used variables.

  • Below find the relevant folders typically containing the persistent configuration of NGINX Proxy (NPM) Manager, they will also be mounted as part of the open-appsec NPM integration docker-compose.yaml so that all your existing configuration should be kept. Only if for some reason you changed the local folder locations for these specific docker volume mounts in the past, please make sure to adjust those as well in the new .env file for the open-appsec NGINX Proxy Manager integration.

    NPM_DATA=./data
    NPM_LETSENCRYPT=./letsencrypt
  • When you perform the first time login with your web browser to the Web UI of the NGINX Proxy Manager (NPM) with open-appsec integration then your existing user credentials for the login should still work, indicating your NPM configuration was kept successfully.

http://[hostname or IP of your host]:81
  • After switching to and loading the new Nginx Proxy Manager (NPM) pages, make sure to clear your browser’s cache and cookies to ensure the updated configuration is applied correctly.

Last updated

Was this helpful?