From 575dc3af4e988d99f23fb83bfbb916df20fb50f6 Mon Sep 17 00:00:00 2001 From: James Carppe Date: Mon, 27 Sep 2021 02:51:17 +0000 Subject: [PATCH] GitBook: [ce-2.6] 15 pages modified --- admin/upgrade/docker.md | 8 ++++---- admin/upgrade/swarm.md | 4 ++-- advanced/cli.md | 14 +++++++------- advanced/reverse-proxy/nginx.md | 6 +++--- advanced/reverse-proxy/traefik.md | 6 +++--- advanced/ssl.md | 6 +++--- start/install/agent/docker/linux.md | 2 +- start/install/agent/docker/wcs.md | 2 +- start/install/agent/docker/wsl.md | 2 +- start/install/server/docker/linux.md | 2 +- start/install/server/docker/wcs.md | 2 +- start/install/server/docker/wsl.md | 2 +- start/install/server/swarm/linux.md | 4 ++-- start/install/server/swarm/wcs.md | 2 +- start/install/server/swarm/wsl.md | 2 +- 15 files changed, 32 insertions(+), 32 deletions(-) diff --git a/admin/upgrade/docker.md b/admin/upgrade/docker.md index a7027be..ccb294b 100644 --- a/admin/upgrade/docker.md +++ b/admin/upgrade/docker.md @@ -25,13 +25,13 @@ docker rm portainer Now that you have stopped and removed the old version of Portainer, you must ensure that you have the latest version of the image locally. You can do this with a `docker pull` command: ```text -docker pull portainer/portainer-ce +docker pull portainer/portainer-ce:2.6.3 ``` Finally, deploy the updated version of Portainer: ```text -docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce +docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:2.6.3 ``` The newest version of Portainer will now be deployed on your system, using the persistent data from the previous version, and will also upgrade the Portainer database to the new version. @@ -95,12 +95,12 @@ docker rm portainer_agent Next, pull the updated version of the image: ```text -docker pull portainer/agent +docker pull portainer/agent:2.6.3 ``` Finally, start the agent with the updated image: ```text -docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent +docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent:2.6.3 ``` diff --git a/admin/upgrade/swarm.md b/admin/upgrade/swarm.md index 2c99b88..16a6d8d 100644 --- a/admin/upgrade/swarm.md +++ b/admin/upgrade/swarm.md @@ -17,13 +17,13 @@ Make note of the service names for Portainer. You will need them later. To upgrade Portainer Server to the latest version, run the command below \(replace the `portainer_portainer` service name if your setup differs\): ```text -docker service update --image portainer/portainer-ce --force portainer_portainer +docker service update --image portainer/portainer-ce:2.6.3 --force portainer_portainer ``` To upgrade the Portainer Agent to the latest version, run the command below \(replace the `portainer_agent` service name if your setup differs\): ```text -docker service update --image portainer/agent --force portainer_agent +docker service update --image portainer/agent:2.6.3 --force portainer_agent ``` This will deploy the newest version of Portainer and the agent across your swarm and upgrade the Portainer database to match. diff --git a/advanced/cli.md b/advanced/cli.md index ce56bfa..c6a1b14 100644 --- a/advanced/cli.md +++ b/advanced/cli.md @@ -158,7 +158,7 @@ docker run --rm httpd:2.4-alpine htpasswd -nbB admin "your-password" | cut -d ": Once the password has been created, specify the admin password from the command line by starting Portainer with the `--admin-password` flag: ```text -docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce --admin-password='$2y$05$8oz75U8m5tI/xT4P0NbSHeE7WyRzOWKRBprfGotwDkhBOGP/u802u' +docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:2.6.3 --admin-password='$2y$05$8oz75U8m5tI/xT4P0NbSHeE7WyRzOWKRBprfGotwDkhBOGP/u802u' ``` ### Method 2: Creating the account using a file @@ -172,7 +172,7 @@ echo -n mypassword > /tmp/portainer_password Next, start the Portainer container: ```text -docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock -v /tmp/portainer_password:/tmp/portainer_password portainer/portainer-ce --admin-password-file /tmp/portainer_password +docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock -v /tmp/portainer_password:/tmp/portainer_password portainer/portainer-ce:2.6.3 --admin-password-file /tmp/portainer_password ``` This also works well with Docker Swarm and Docker Secrets: @@ -190,7 +190,7 @@ docker service create \ --replicas=1 \ --constraint 'node.role == manager' \ --mount type=bind,src=/var/run/docker.sock,dst=/var/run/docker.sock \ - portainer/portainer-ce \ + portainer/portainer-ce:2.6.3 \ --admin-password-file '/run/secrets/portainer-pass' \ -H unix:///var/run/docker.sock ``` @@ -206,13 +206,13 @@ docker run -d --label owner=acme nginx To hide this container, when starting Portainer add the `-l owner=acme` option on the CLI: ```text -docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce -l owner=acme +docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:2.6.3 -l owner=acme ``` To hide multiple containers, repeat the `-l` flag: ```text -docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce -l owner=acme -l service=secret +docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:2.6.3 -l owner=acme -l service=secret ``` ## Using your own logo @@ -224,7 +224,7 @@ Images must be exactly 155px by 55px in size. Replace our logo with your own using the `--logo` flag to specify the location of the image file: ```text -docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce --logo "https://www.docker.com/sites/all/themes/docker/assets/images/brand-full.svg" +docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:2.6.3 --logo "https://www.docker.com/sites/all/themes/docker/assets/images/brand-full.svg" ``` You can also update the logo in the Portainer UI \(**Settings** menu\). @@ -240,6 +240,6 @@ Portainer allows you to rapidly [deploy containers using app templates](../user/ Templates are loaded once when Portainer is first started. If you already deployed a Portainer instance then decide to use your own templates, you’ll need to clear the default templates either in the user interface or through the HTTP API. Use the `--templates` flag to specify a URL where the template file can be accessed via HTTP. ```text -docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce --templates http://my-host.my-domain/templates.json +docker run -d -p 9000:9000 -p 8000:8000 -v /var/run/docker.sock:/var/run/docker.sock portainer/portainer-ce:2.6.3 --templates http://my-host.my-domain/templates.json ``` diff --git a/advanced/reverse-proxy/nginx.md b/advanced/reverse-proxy/nginx.md index d5d9821..6c0f86c 100644 --- a/advanced/reverse-proxy/nginx.md +++ b/advanced/reverse-proxy/nginx.md @@ -21,7 +21,7 @@ services: - "/var/run/docker.sock:/tmp/docker.sock:ro" portainer: - image: portainer/portainer-ce + image: portainer/portainer-ce:2.6.3 command: -H unix:///var/run/docker.sock restart: always environment: @@ -93,7 +93,7 @@ services: - "./vhost.d:/etc/nginx/vhost.d:ro" agent: - image: portainer/agent + image: portainer/agent:2.6.3 environment: # REQUIRED: Should be equal to the service name prefixed by "tasks." when # deployed inside an overlay network @@ -111,7 +111,7 @@ services: constraints: [node.platform.os == linux] portainer: - image: portainer/portainer-ce + image: portainer/portainer-ce:2.6.3 command: -H tcp://tasks.agent:9001 --tlsskipverify volumes: - data:/data diff --git a/advanced/reverse-proxy/traefik.md b/advanced/reverse-proxy/traefik.md index 9750fd3..78998a5 100644 --- a/advanced/reverse-proxy/traefik.md +++ b/advanced/reverse-proxy/traefik.md @@ -39,7 +39,7 @@ services: - "traefik.http.middlewares.redirect-to-https.redirectscheme.scheme=https" portainer: - image: portainer/portainer-ce + image: portainer/portainer-ce:2.6.3 command: -H unix:///var/run/docker.sock restart: always volumes: @@ -150,7 +150,7 @@ services: - "/var/run/docker.sock:/var/run/docker.sock:ro" agent: - image: portainer/agent + image: portainer/agent:2.6.3 environment: # REQUIRED: Should be equal to the service name prefixed by "tasks." when # deployed inside an overlay network @@ -168,7 +168,7 @@ services: constraints: [node.platform.os == linux] portainer: - image: portainer/portainer-ce + image: portainer/portainer-ce:2.6.3 command: -H tcp://tasks.agent:9001 --tlsskipverify volumes: - data:/data diff --git a/advanced/ssl.md b/advanced/ssl.md index fb4678b..89ac526 100644 --- a/advanced/ssl.md +++ b/advanced/ssl.md @@ -24,7 +24,7 @@ docker run -d -p 443:9000 -p 8000:8000 \ -v /var/run/docker.sock:/var/run/docker.sock \ -v portainer_data:/data \ -v ~/local-certs:/certs \ - portainer/portainer-ce --ssl --sslcert /certs/portainer.crt --sslkey /certs/portainer.key + portainer/portainer-ce:2.6.3 --ssl --sslcert /certs/portainer.crt --sslkey /certs/portainer.key ``` As an alternative, Certbot can be used to generate a certificate and a key. However, because Docker has issues with symlinks, if you use Certbot, you will need to pass both the 'live' and 'archive' directories as volumes \(shown below\). @@ -36,7 +36,7 @@ docker run -d -p 443:9000 -p 8000:8000 \ -v portainer-data:/data \ -v /etc/letsencrypt/live/yourdomain:/certs/live/yourdomain:ro \ -v /etc/letsencrypt/archive/yourdomain:/certs/archive/yourdomain:ro \ - portainer/portainer-ce --ssl --sslcert /certs/live/yourdomain/cert.pem --sslkey /certs/live/yourdomain/privkey.pem + portainer/portainer-ce:2.6.3 --ssl --sslcert /certs/live/yourdomain/cert.pem --sslkey /certs/live/yourdomain/privkey.pem ``` Now, you can navigate to `https://$ip-docker-host`. @@ -77,7 +77,7 @@ services: constraints: [node.platform.os == linux] portainer: - image: portainer/portainer-ce:latest + image: portainer/portainer-ce:2.6.3 command: -H tcp://tasks.agent:9001 --tlsskipverify --ssl --sslcert /run/secrets/portainer.example.com.cer --sslkey /run/secrets/portainer.example.com.key ports: - "9000:9000" diff --git a/start/install/agent/docker/linux.md b/start/install/agent/docker/linux.md index c17e2f3..6061eb8 100644 --- a/start/install/agent/docker/linux.md +++ b/start/install/agent/docker/linux.md @@ -21,7 +21,7 @@ The installation instructions also make the following assumptions about your env Run the following command to deploy the Portainer Agent: ```bash -docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent +docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent:2.6.3 ``` ## Adding Your New Endpoint diff --git a/start/install/agent/docker/wcs.md b/start/install/agent/docker/wcs.md index 4016753..57b67cc 100644 --- a/start/install/agent/docker/wcs.md +++ b/start/install/agent/docker/wcs.md @@ -15,7 +15,7 @@ You will need: To run Portainer Agent in a Windows Container scenario, you need to execute the following commands: ```bash -docker run -d -p 9001:9001 --name portainer_agent --restart=always -v \\.\pipe\docker_engine:\\.\pipe\docker_engine portainer/agent +docker run -d -p 9001:9001 --name portainer_agent --restart=always -v \\.\pipe\docker_engine:\\.\pipe\docker_engine portainer/agent:2.6.3 ``` ## Adding Your New Endpoint diff --git a/start/install/agent/docker/wsl.md b/start/install/agent/docker/wsl.md index 3368e8d..b7f0904 100644 --- a/start/install/agent/docker/wsl.md +++ b/start/install/agent/docker/wsl.md @@ -22,7 +22,7 @@ The installation instructions also make the following assumptions about your env Run the following command to deploy the Portainer Agent: ```bash -docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent +docker run -d -p 9001:9001 --name portainer_agent --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /var/lib/docker/volumes:/var/lib/docker/volumes portainer/agent:2.6.3 ``` ## Adding Your New Endpoint diff --git a/start/install/server/docker/linux.md b/start/install/server/docker/linux.md index 31744cf..556714e 100644 --- a/start/install/server/docker/linux.md +++ b/start/install/server/docker/linux.md @@ -31,7 +31,7 @@ docker volume create portainer_data Then, download and install the Portainer Server container: ```bash -docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce +docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:2.6.3 ``` Portainer Server has now been installed. You can check to see whether the Portainer Server container has started by running `docker ps`: diff --git a/start/install/server/docker/wcs.md b/start/install/server/docker/wcs.md index fa5651d..88bc93a 100644 --- a/start/install/server/docker/wcs.md +++ b/start/install/server/docker/wcs.md @@ -48,7 +48,7 @@ docker volume create portainer_data Then, download and install the Portainer Server container: ```text -docker run -d -p 9000:9000 --name portainer --restart always -v \.\pipe\docker_engine:\.\pipe\docker_engine -v portainer_data:C:\data portainer/portainer-ce +docker run -d -p 9000:9000 --name portainer --restart always -v \.\pipe\docker_engine:\.\pipe\docker_engine -v portainer_data:C:\data portainer/portainer-ce:2.6.3 ``` ## Logging In diff --git a/start/install/server/docker/wsl.md b/start/install/server/docker/wsl.md index e506546..ee30452 100644 --- a/start/install/server/docker/wsl.md +++ b/start/install/server/docker/wsl.md @@ -32,7 +32,7 @@ docker volume create portainer_data Then, download and install the Portainer Server container: ```bash -docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce +docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:2.6.3 ``` Portainer Server has now been installed. You can check to see whether the Portainer Server container has started by running `docker ps`: diff --git a/start/install/server/swarm/linux.md b/start/install/server/swarm/linux.md index 6be2d32..12deab0 100644 --- a/start/install/server/swarm/linux.md +++ b/start/install/server/swarm/linux.md @@ -32,7 +32,7 @@ Portainer can be directly deployed as a service in your Docker cluster. Note tha First, retrieve the stack YML manifest: ```text -curl -L https://downloads.portainer.io/portainer-agent-stack.yml -o portainer-agent-stack.yml +curl -L https://downloads.portainer.io/ce2.6.3/portainer-agent-stack.yml -o portainer-agent-stack.yml ``` Then, use the downloaded YML manifest to deploy your stack: @@ -47,7 +47,7 @@ Portainer Server and the Agents have now been installed. You can check to see wh root@manager01:~# docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 59ee466f6b15 portainer/agent:latest "./agent" About a minute ago Up About a minute portainer_agent.xbb8k6r7j1tk9gozjku7e43wr.5sa6b3e8cl6hyu0snlt387sgv -2db7dd4bfba0 portainer/portainer-ce:latest "/portainer -H tcp:/…" About a minute ago Up About a minute 8000/tcp, 9000/tcp portainer_portainer.1.gpuvu3pqmt1m19zxfo44v7izx +2db7dd4bfba0 portainer/portainer-ce:2.6.3 "/portainer -H tcp:/…" About a minute ago Up About a minute 8000/tcp, 9000/tcp portainer_portainer.1.gpuvu3pqmt1m19zxfo44v7izx ``` ## Logging In diff --git a/start/install/server/swarm/wcs.md b/start/install/server/swarm/wcs.md index f0fb9a2..7250b2a 100644 --- a/start/install/server/swarm/wcs.md +++ b/start/install/server/swarm/wcs.md @@ -50,7 +50,7 @@ Portainer can be directly deployed as a service in your Docker cluster. Note tha You can use our YML manifest to run Portainer in Windows using Windows Containers. In PowerShell, run: ```bash -curl https://downloads.portainer.io/portainer_windows_stack.yml -o portainer_windows_stack.yml +curl https://downloads.portainer.io/ce2.6.3/portainer_windows_stack.yml -o portainer_windows_stack.yml ``` This will download the YML manifest. To deploy using this, run: diff --git a/start/install/server/swarm/wsl.md b/start/install/server/swarm/wsl.md index 2ea7f2b..a461e18 100644 --- a/start/install/server/swarm/wsl.md +++ b/start/install/server/swarm/wsl.md @@ -37,7 +37,7 @@ docker swarm init To begin the installation, first retrieve the stack YML manifest: ```bash -curl -L https://downloads.portainer.io/portainer-agent-stack.yml -o portainer-agent-stack.yml +curl -L https://downloads.portainer.io/ce2.6.3/portainer-agent-stack.yml -o portainer-agent-stack.yml ``` Then, use the downloaded YML manifest to deploy your stack: