Nginx Proxy Manager is a simple yet powerful tool that allows you to manage your Nginx proxy hosts with a user-friendly web interface. It is especially useful for those who want to set up reverse proxies and SSL certificates easily. In this guide, we will walk through the steps to install Nginx Proxy Manager using Docker.

Step 1: Install Docker

If you haven't installed Docker yet, you can do so by following these commands:

sudo apt update
sudo apt install -y docker.io docker-compose

Step 2: Create a Docker Network

Create a Docker network for Nginx Proxy Manager:

docker network create nginx-proxy

Step 3: Create a Directory for Nginx Proxy Manager

Create a directory to store your Nginx Proxy Manager configuration:

mkdir ~/nginx-proxy-manager
cd ~/nginx-proxy-manager

Step 4: Create a Docker Compose File

Create a docker-compose.yml file in the Nginx Proxy Manager directory:

nano docker-compose.yml

Insert the following configuration:

version: '3'
services:
  npm:
    image: jc21/nginx-proxy-manager
    container_name: nginx-proxy-manager
    restart: always
    ports:
      - "80:80"
      - "443:443"
      - "81:81"
    environment:
      DB_MYSQL_HOST: db
      DB_MYSQL_PORT: 3306
      DB_MYSQL_USER: npm
      DB_MYSQL_PASSWORD: npm_password
      DB_MYSQL_DATABASE: npm
    volumes:
      - ./data:/data
      - ./letsencrypt:/etc/letsencrypt
    networks:
      - nginx-proxy

  db:
    image: mysql:5.7
    container_name: npm_db
    restart: always
    environment:
      MYSQL_ROOT_PASSWORD: root_password
      MYSQL_DATABASE: npm
      MYSQL_USER: npm
      MYSQL_PASSWORD: npm_password
    volumes:
      - ./mysql:/var/lib/mysql
    networks:
      - nginx-proxy

networks:
  nginx-proxy:
    external: true

Step 5: Start Nginx Proxy Manager

Navigate to the directory where you created the docker-compose.yml file and run the following command:

docker-compose up -d

Step 6: Access Nginx Proxy Manager

Once the containers are running, you can access the Nginx Proxy Manager web interface by navigating to:

http://your_server_ip:81

Log in using the default credentials:

  • Email: admin@example.com
  • Password: changeme

Step 7: Set Up Proxy Hosts

After logging in, you can start configuring your proxy hosts. Click on the Proxy Hosts tab and add a new proxy host by providing the necessary details like domain name, forwarding IP, and SSL settings.

Conclusion

You have successfully installed and set up Nginx Proxy Manager using Docker. This tool simplifies the management of your Nginx reverse proxy and SSL certificates.

If you're looking for a reliable hosting solution for your Nginx Proxy Manager, consider using Windows VPS UK. With Windows VPS, you can host your applications efficiently and ensure high performance. Whether you need VPS UK Windows or Windows Virtual Private Servers, you'll find a solution that meets your requirements.

For larger deployments or enterprise needs, explore Windows Virtual Dedicated Server Hosting or Virtual Private Server Hosting Windows. Whether you're located in the UK, Italy, or elsewhere, Windows VPS Italy and UK VPS Windows offer reliable hosting options. Visit Windows VPS Hosting UK to discover the best hosting solutions for your Nginx Proxy Manager deployment.

Was this answer helpful? 0 Users Found This Useful (0 Votes)