this post was submitted on 20 Nov 2023
1 points (100.0% liked)

Portainer

28 readers
0 users here now

Portainer Community Edition is a lightweight service delivery platform for containerized applications that can be used to manage Docker, Swarm, Kubernetes and ACI environments.

founded 11 months ago
MODERATORS
 

Hi all!

I am looking at trying to get NPM - NGINX proxy manager working, and for the life of me cant get it working.

git is installed, and i have tried with #master and without, still no luck, so now i am trying here.

maybe i am going the wrong way here? I just want to add NPM to my container list.

cheers

https://preview.redd.it/m8xh39k3xh1c1.png?width=1155&format=png&auto=webp&s=0bee7104c89d2724f9da23fc280e57fc1351596b

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 1 points 10 months ago

You shouldn't need to build the image - the image already exists on Docker Hub. What you want to do is create a container (or stack) that uses the existing image on Docker Hub. Here's a slightly modified version of the stack file from the NPM documentation that you can deploy in Portainer (the only change I've made is to turn the relative path bind mounts into named volumes):

version: '3.8'
services:
  app:
    image: 'jc21/nginx-proxy-manager:latest'
    restart: unless-stopped
    ports:
      - '80:80'
      - '443:443'
      - '81:81'

    volumes:
      - data:/data
      - letsencrypt:/etc/letsencrypt

volumes:
  data:
  letsencrypt:

In Portainer, go to Stacks, click Add stack, give the stack a name, then paste this into the Web editor and deploy.

Building an image is generally reserved for when you are either creating an image from scratch or are extending an existing image with your own modifications. Simply deploying a container from an image that someone else has created doesn't require any image building.