mirror of
https://github.com/jc21/nginx-proxy-manager.git
synced 2024-08-30 18:22:48 +00:00
Updated docs, new docker tags
This commit is contained in:
parent
a8dd55431a
commit
2d8b5b814e
12
Jenkinsfile
vendored
12
Jenkinsfile
vendored
@ -9,8 +9,8 @@ pipeline {
|
|||||||
BASE_IMAGE_NAME = "jc21/nginx-proxy-manager-base"
|
BASE_IMAGE_NAME = "jc21/nginx-proxy-manager-base"
|
||||||
TEMP_IMAGE_NAME = "nginx-proxy-manager-build_${BUILD_NUMBER}"
|
TEMP_IMAGE_NAME = "nginx-proxy-manager-build_${BUILD_NUMBER}"
|
||||||
TEMP_IMAGE_NAME_ARM = "nginx-proxy-manager-arm-build_${BUILD_NUMBER}"
|
TEMP_IMAGE_NAME_ARM = "nginx-proxy-manager-arm-build_${BUILD_NUMBER}"
|
||||||
//TAG_VERSION = getPackageVersion()
|
TAG_VERSION = getPackageVersion()
|
||||||
TAG_VERSION = "preview"
|
MAJOR_VERSION = "2"
|
||||||
}
|
}
|
||||||
stages {
|
stages {
|
||||||
stage('Prepare') {
|
stage('Prepare') {
|
||||||
@ -36,13 +36,17 @@ pipeline {
|
|||||||
// Private Registry
|
// Private Registry
|
||||||
sh 'docker tag $TEMP_IMAGE_NAME $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION'
|
sh 'docker tag $TEMP_IMAGE_NAME $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION'
|
||||||
sh 'docker push $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION'
|
sh 'docker push $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION'
|
||||||
|
sh 'docker tag $TEMP_IMAGE_NAME $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$MAJOR_VERSION'
|
||||||
|
sh 'docker push $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$MAJOR_VERSION'
|
||||||
|
|
||||||
// Dockerhub
|
// Dockerhub
|
||||||
sh 'docker tag $TEMP_IMAGE_NAME docker.io/jc21/$IMAGE_NAME:$TAG_VERSION'
|
sh 'docker tag $TEMP_IMAGE_NAME docker.io/jc21/$IMAGE_NAME:$TAG_VERSION'
|
||||||
|
sh 'docker tag $TEMP_IMAGE_NAME docker.io/jc21/$IMAGE_NAME:$MAJOR_VERSION'
|
||||||
|
|
||||||
withCredentials([usernamePassword(credentialsId: 'jc21-dockerhub', passwordVariable: 'dpass', usernameVariable: 'duser')]) {
|
withCredentials([usernamePassword(credentialsId: 'jc21-dockerhub', passwordVariable: 'dpass', usernameVariable: 'duser')]) {
|
||||||
sh "docker login -u '${duser}' -p '$dpass'"
|
sh "docker login -u '${duser}' -p '$dpass'"
|
||||||
sh 'docker push docker.io/jc21/$IMAGE_NAME:$TAG_VERSION'
|
sh 'docker push docker.io/jc21/$IMAGE_NAME:$TAG_VERSION'
|
||||||
|
sh 'docker push docker.io/jc21/$IMAGE_NAME:$MAJOR_VERSION'
|
||||||
}
|
}
|
||||||
|
|
||||||
sh 'docker rmi $TEMP_IMAGE_NAME'
|
sh 'docker rmi $TEMP_IMAGE_NAME'
|
||||||
@ -67,13 +71,17 @@ pipeline {
|
|||||||
// Private Registry
|
// Private Registry
|
||||||
sh 'docker tag $TEMP_IMAGE_NAME_ARM $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION-armhf'
|
sh 'docker tag $TEMP_IMAGE_NAME_ARM $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION-armhf'
|
||||||
sh 'docker push $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION-armhf'
|
sh 'docker push $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$TAG_VERSION-armhf'
|
||||||
|
sh 'docker tag $TEMP_IMAGE_NAME_ARM $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$MAJOR_VERSION-armhf'
|
||||||
|
sh 'docker push $DOCKER_PRIVATE_REGISTRY/$IMAGE_NAME:$MAJOR_VERSION-armhf'
|
||||||
|
|
||||||
// Dockerhub
|
// Dockerhub
|
||||||
sh 'docker tag $TEMP_IMAGE_NAME_ARM docker.io/jc21/$IMAGE_NAME:$TAG_VERSION-armhf'
|
sh 'docker tag $TEMP_IMAGE_NAME_ARM docker.io/jc21/$IMAGE_NAME:$TAG_VERSION-armhf'
|
||||||
|
sh 'docker tag $TEMP_IMAGE_NAME_ARM docker.io/jc21/$IMAGE_NAME:$MAJOR_VERSION-armhf'
|
||||||
|
|
||||||
withCredentials([usernamePassword(credentialsId: 'jc21-dockerhub', passwordVariable: 'dpass', usernameVariable: 'duser')]) {
|
withCredentials([usernamePassword(credentialsId: 'jc21-dockerhub', passwordVariable: 'dpass', usernameVariable: 'duser')]) {
|
||||||
sh "docker login -u '${duser}' -p '$dpass'"
|
sh "docker login -u '${duser}' -p '$dpass'"
|
||||||
sh 'docker push docker.io/jc21/$IMAGE_NAME:$TAG_VERSION-armhf'
|
sh 'docker push docker.io/jc21/$IMAGE_NAME:$TAG_VERSION-armhf'
|
||||||
|
sh 'docker push docker.io/jc21/$IMAGE_NAME:$MAJOR_VERSION-armhf'
|
||||||
}
|
}
|
||||||
|
|
||||||
sh 'docker rmi $TEMP_IMAGE_NAME_ARM'
|
sh 'docker rmi $TEMP_IMAGE_NAME_ARM'
|
||||||
|
21
README.md
21
README.md
@ -12,7 +12,7 @@ running at home or otherwise, including free SSL, without having to know too muc
|
|||||||
----------
|
----------
|
||||||
|
|
||||||
**WARNING: Version 2 a complete rewrite!** If you are using the `latest` docker tag and update to version 2
|
**WARNING: Version 2 a complete rewrite!** If you are using the `latest` docker tag and update to version 2
|
||||||
without preparation, horrible things might happen. Refer to the [Migrating Documentation](doc/MIGRATING.md).
|
without preparation, horrible things might happen. Refer to the [Importing Documentation](doc/IMPORTING.md).
|
||||||
|
|
||||||
----------
|
----------
|
||||||
|
|
||||||
@ -22,7 +22,7 @@ without preparation, horrible things might happen. Refer to the [Migrating Docum
|
|||||||
- Easily create forwarding domains, redirections, streams and 404 hosts without knowing anything about Nginx
|
- Easily create forwarding domains, redirections, streams and 404 hosts without knowing anything about Nginx
|
||||||
- Free SSL using Let's Encrypt or provide your own custom SSL certificates
|
- Free SSL using Let's Encrypt or provide your own custom SSL certificates
|
||||||
- Access Lists and basic HTTP Authentication for your hosts
|
- Access Lists and basic HTTP Authentication for your hosts
|
||||||
- -Advanced Nginx configuration available for super users- TODO
|
- Advanced Nginx configuration available for super users
|
||||||
- User management, permissions and audit log
|
- User management, permissions and audit log
|
||||||
|
|
||||||
|
|
||||||
@ -41,9 +41,22 @@ Please consult the [installation instructions](doc/INSTALL.md) for a complete gu
|
|||||||
if you just want to get up and running in the quickest time possible, grab all the files in the `doc/example/` folder and run `docker-compose up -d`
|
if you just want to get up and running in the quickest time possible, grab all the files in the `doc/example/` folder and run `docker-compose up -d`
|
||||||
|
|
||||||
|
|
||||||
## Migrating from Version 1?
|
## Importing from Version 1?
|
||||||
|
|
||||||
Here's a [guide for you to migrate your configuration](doc/MIGRATING.md).
|
Here's a [guide for you to migrate your configuration](doc/IMPORTING.md). You should definitely read the [installation instructions](doc/INSTALL.md) first though.
|
||||||
|
|
||||||
|
**Why should I?**
|
||||||
|
|
||||||
|
Version 2 has the following improvements:
|
||||||
|
|
||||||
|
- Management security and multiple user access
|
||||||
|
- User permissions and visibility
|
||||||
|
- Custom SSL certificate support
|
||||||
|
- Audit log of changes
|
||||||
|
- Broken nginx config detection
|
||||||
|
- Multiple domains in Let's Encrypt certificates
|
||||||
|
- Wildcard domain name support (not available with a Let's Encrypt certificate though)
|
||||||
|
- It's super sexy
|
||||||
|
|
||||||
|
|
||||||
## Administration
|
## Administration
|
||||||
|
57
doc/IMPORTING.md
Normal file
57
doc/IMPORTING.md
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
## Importing from Version 1
|
||||||
|
|
||||||
|
Thanks for using Nginx Proxy Manager version 1. It sucked.
|
||||||
|
|
||||||
|
But it worked.
|
||||||
|
|
||||||
|
This guide will let your import your configuration from version 1 to version 2.
|
||||||
|
|
||||||
|
**IMPORTANT: This will make changes to your `letsencrypt` folder and certificate files!** Make sure you back them up first.
|
||||||
|
|
||||||
|
|
||||||
|
### Link your previous folders in your new docker stack
|
||||||
|
|
||||||
|
In version 1, the docker configuration asked for a `config` folder to be linked and a `letsencrypt` folder. However in version 2, the
|
||||||
|
configuration exists in the database, so the `config` folder is no longer required. However if you have this folder linked in a
|
||||||
|
version 2 stack, the application will automatically import that configuration the first time it finds it.
|
||||||
|
|
||||||
|
Following the [example configuration](../example):
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
version: "3"
|
||||||
|
services:
|
||||||
|
app:
|
||||||
|
image: jc21/nginx-proxy-manager:2
|
||||||
|
restart: always
|
||||||
|
ports:
|
||||||
|
- 80:80
|
||||||
|
- 81:81
|
||||||
|
- 443:443
|
||||||
|
volumes:
|
||||||
|
- ./config.json:/app/config/production.json
|
||||||
|
- ./data:/data
|
||||||
|
- ./letsencrypt:/etc/letsencrypt # this is your previous letsencrypt folder
|
||||||
|
- ./config:/config # this is your previous config folder
|
||||||
|
depends_on:
|
||||||
|
- db
|
||||||
|
db:
|
||||||
|
image: mariadb
|
||||||
|
restart: always
|
||||||
|
environment:
|
||||||
|
MYSQL_ROOT_PASSWORD: "password123"
|
||||||
|
MYSQL_DATABASE: "nginxproxymanager"
|
||||||
|
MYSQL_USER: "nginxproxymanager"
|
||||||
|
MYSQL_PASSWORD: "password123"
|
||||||
|
volumes:
|
||||||
|
- ./data/mysql:/var/lib/mysql
|
||||||
|
```
|
||||||
|
|
||||||
|
After you start the stack, the import will begin just after database initialize.
|
||||||
|
|
||||||
|
Some notes:
|
||||||
|
- After importing, a file is created in the `config` folder to signify that it has been imported and should not be imported again.
|
||||||
|
- Because no users previously existed in the version 1 config, the `admin@example.com` user will own all of the imported data.
|
||||||
|
- If you were crazy like me and used Nginx Proxy Manager version 1 to proxy the Admin interface behind a Access List, you should
|
||||||
|
really disable the access list for that proxy host in version 1 before importing in to version 2. The app doesn't like being behind basic
|
||||||
|
authentication and it's own internal authentication. If you forgot to do this before importing, just hit the admin interface directly
|
||||||
|
on port 81 to get around your basic authentication access list.
|
@ -3,7 +3,7 @@
|
|||||||
There's a few ways to configure this app depending on:
|
There's a few ways to configure this app depending on:
|
||||||
|
|
||||||
- Whether you use `docker-compose` or vanilla docker
|
- Whether you use `docker-compose` or vanilla docker
|
||||||
- Which architecture you're running it on (raspberry pi also supported)
|
- Which architecture you're running it on (raspberry pi also supported - Testers wanted!)
|
||||||
|
|
||||||
### Configuration File
|
### Configuration File
|
||||||
|
|
||||||
@ -36,7 +36,7 @@ affect the login and session management of the application. If these keys change
|
|||||||
|
|
||||||
### Database
|
### Database
|
||||||
|
|
||||||
This app doesn't come with a database, you have to provide one yourself. Currently `mysql` and `postgres` databases are supported.
|
This app doesn't come with a database, you have to provide one yourself. Currently only `mysql/mariadb` is supported.
|
||||||
|
|
||||||
It's easy to use another docker container for your database also and link it as part of the docker stack. Here's an example:
|
It's easy to use another docker container for your database also and link it as part of the docker stack. Here's an example:
|
||||||
|
|
||||||
@ -46,7 +46,10 @@ services:
|
|||||||
app:
|
app:
|
||||||
image: jc21/nginx-proxy-manager:2
|
image: jc21/nginx-proxy-manager:2
|
||||||
restart: always
|
restart: always
|
||||||
network_mode: host
|
ports:
|
||||||
|
- 80:80
|
||||||
|
- 81:81
|
||||||
|
- 443:443
|
||||||
volumes:
|
volumes:
|
||||||
- ./config.json:/app/config/production.json
|
- ./config.json:/app/config/production.json
|
||||||
- ./data:/data
|
- ./data:/data
|
||||||
@ -76,7 +79,10 @@ services:
|
|||||||
app:
|
app:
|
||||||
image: jc21/nginx-proxy-manager:2
|
image: jc21/nginx-proxy-manager:2
|
||||||
restart: always
|
restart: always
|
||||||
network_mode: host
|
ports:
|
||||||
|
- 80:80
|
||||||
|
- 81:81
|
||||||
|
- 443:443
|
||||||
volumes:
|
volumes:
|
||||||
- ./config.json:/app/config/production.json
|
- ./config.json:/app/config/production.json
|
||||||
- ./data:/data
|
- ./data:/data
|
||||||
@ -88,7 +94,9 @@ Vanilla Docker:
|
|||||||
```bash
|
```bash
|
||||||
docker run -d \
|
docker run -d \
|
||||||
--name nginx-proxy-manager \
|
--name nginx-proxy-manager \
|
||||||
--network host \
|
-p 80:80 \
|
||||||
|
-p 81:81 \
|
||||||
|
-p 443:443 \
|
||||||
-v /path/to/config.json:/app/config/production.json \
|
-v /path/to/config.json:/app/config/production.json \
|
||||||
-v /path/to/data:/data \
|
-v /path/to/data:/data \
|
||||||
-v /path/to/letsencrypt:/etc/letsencrypt \
|
-v /path/to/letsencrypt:/etc/letsencrypt \
|
||||||
@ -102,20 +110,11 @@ I have created a `armhf` docker container just for you. There may be issues with
|
|||||||
if you have issues please report them here.
|
if you have issues please report them here.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Postgres:
|
|
||||||
docker run -d \
|
|
||||||
--name nginx-proxy-manager-db \
|
|
||||||
--network host \
|
|
||||||
-e POSTGRES_DB=nginxproxymanager \
|
|
||||||
-e POSTGRES_USER=nginxproxymanager \
|
|
||||||
-e POSTGRES_PASSWORD=password123 \
|
|
||||||
-v /path/to/postgresql:/var/lib/postgresql/data \
|
|
||||||
zsoltm/postgresql-armhf
|
|
||||||
|
|
||||||
# NPM:
|
|
||||||
docker run -d \
|
docker run -d \
|
||||||
--name nginx-proxy-manager-app \
|
--name nginx-proxy-manager-app \
|
||||||
--network host \
|
-p 80:80 \
|
||||||
|
-p 81:81 \
|
||||||
|
-p 443:443 \
|
||||||
-v /path/to/config.json:/app/config/production.json \
|
-v /path/to/config.json:/app/config/production.json \
|
||||||
-v /path/to/data:/data \
|
-v /path/to/data:/data \
|
||||||
-v /path/to/letsencrypt:/etc/letsencrypt \
|
-v /path/to/letsencrypt:/etc/letsencrypt \
|
||||||
|
@ -1,3 +0,0 @@
|
|||||||
## Migrating from Version 1
|
|
||||||
|
|
||||||
TODO
|
|
@ -3,12 +3,19 @@ services:
|
|||||||
app:
|
app:
|
||||||
image: jc21/nginx-proxy-manager:2
|
image: jc21/nginx-proxy-manager:2
|
||||||
restart: always
|
restart: always
|
||||||
|
ports:
|
||||||
|
- 80:80
|
||||||
|
- 81:81
|
||||||
|
- 443:443
|
||||||
volumes:
|
volumes:
|
||||||
- ./config.json:/app/config/production.json
|
- ./config.json:/app/config/production.json
|
||||||
- ./data:/data
|
- ./data:/data
|
||||||
- ./letsencrypt:/etc/letsencrypt
|
- ./letsencrypt:/etc/letsencrypt
|
||||||
depends_on:
|
depends_on:
|
||||||
- db
|
- db
|
||||||
|
environment:
|
||||||
|
# if you want pretty colors in your docker logs:
|
||||||
|
- FORCE_COLOR=1
|
||||||
db:
|
db:
|
||||||
image: mariadb
|
image: mariadb
|
||||||
restart: always
|
restart: always
|
||||||
|
Loading…
Reference in New Issue
Block a user