Nginx Proxy Manager#

sudo apt update && sudo apt upgrade -y

Step1: Create a network to route all application’s traffic through it:

docker network create npm-net

curl https://get.acme.sh | sh

source ~/.bashrc

~/.acme.sh/acme.sh –register-account -m you@your-email.com –server letsencrypt

~/.acme.sh/acme.sh –issue –dns -d nginxp.gagsingh.com –yes-I-know-dns-manual-mode-enough-go-ahead-please -m gagansingh901@gmail.com

acme.sh –renew -d nginxp.gagsingh.com –yes-I-know-dns-manual-mode-enough-go-ahead-please

mkdir -p ~/nginxproxy/data/custom_ssl

sudo chown -R pi:pi ~/nginxproxy/data/custom_ssl

cp ~/.acme.sh/nginxp.gagsingh.com_ecc/fullchain.cer ~/nginxproxy/data/custom_ssl/nginxp.fullchain.cer

cp ~/.acme.sh/nginxp.gagsingh.com_ecc/nginxp.gagsingh.com.key ~/nginxproxy/data/custom_ssl/nginxp.key

scp -r pi@192.168.1.5:/nginxproxy/data/custom_ssl/


Hostinger API

qNLWfRCWhdidf65NKFyTKOQ7JNl9TFsZWcdLfpun5c586af5

curl -X GET “https://developers.hostinger.com/api/vps/v1/virtual-machines" \

-H “Authorization: Bearer qNLWfRCWhdidf65NKFyTKOQ7JNl9TFsZWcdLfpun5c586af5” \

-H “Content-Type: application/json”


Step2: Create a folder:

mkdir nginxproxy

Step3: Navigate to the folder:

cd nginxproxy

Step4: Create and edit a file docker-compose.yml:

sudo nano docker-compose.yml

Step5: Modify the file as per your requirements:

| services: app: image: ‘jc21/nginx-proxy-manager:latest’ 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:

Uncomment this if you want to change the location of#

the SQLite DB file within the container#

DB_SQLITE_FILE: “/data/database.sqlite”#

Uncomment this if IPv6 is not enabled on your host#

DISABLE_IPV6: ’true’#

networks:

  • npm-net volumes:
  • ./data:/data
  • ./letsencrypt:/etc/letsencrypt networks: npm-net:
    external: true

Step6: Install and Run the docker file:

docker compose up -d

Step7: Open Nginx Proxy Manager by visiting:

http://youripaddress:81

Step8: Change the default Username and Password:

Email admin@example.com
Password changeme