Hi, I’m @Luo Zhu

This article was first published on luo Zhu’s official website

This article synchronizes in the public account “luo Zhu early teahouse”, reprint please contact the author.

Creation is not easy, form a habit, quality three even!

What is the pagoda panel?

Pagoda Linux panel is the server management software to improve the efficiency of operation and maintenance. It supports more than 100 server management functions, such as one-click LAMP/LNMP/ cluster/monitoring/website /FTP/ database /JAVA. There are 30 professional team research and development and maintenance, after more than 200 versions of the iteration, full function, less error and enough security, has been approved by millions of users worldwide installation. Operation and maintenance to efficient, installed pagodas.

Why use Docker installation?

  1. Environment isolation, a host can deploy multiple sets of services
  2. Pagoda has a high degree of host control and complex dependency relationship, while Docker can ensure that pagoda service does not affect other services of host computer.
  3. Because of the isolation and host machine environment, it is not easy to be Trojan tools.
  4. The compatibility order of the pagoda panel isX > Debian10 > Ubuntu 20.04 > cenots8. x > Ubuntu 18.04 > other systems, and the user’s host is varied, in order to obtain the best compatibility, using Docker deployment is the only choice.
  5. Docker has low administration cost and easy migration.
  6. Containers can be managed at any time without resetting the server.

Docker installation

Script installation is recommended:

curl -fsSL https://get.docker.com -o get-docker.sh

sudo sh get-docker.sh --mirror Aliyun
Copy the code

After the installation is successful, the Docker service will be automatically started. You can use systemctl is-enabled docker to check whether the Docker service starts automatically after startup. If not, use systemctl enable docker to set autoboot.

Agent to accelerate

Run nano /etc/docker-daemon. json and write the following information:

{
  "registry-mirrors": [
    "https://registry.docker-cn.com"."https://mirror.baidubce.com"."https://hub-mirror.c.163.com"]}Copy the code

Beginning mouth tutorial, not open can not be used

Ports required by the pagoda: 8888, 888, 20, 21, 80, 443

Install the pagoda mirror

curl -fsSL https://youngjuning.js.org/shell/baota/install.sh | sh
Copy the code
  • /www/wwwrootMounted on the host machine~/wwwrootdirectory
  • /wwwMounted on thebaota_wwwVolume, i.e.,/var/lib/docker/volumes/baota_www/

The script above is for my convenience, Docker run-tid –name baota –net=host –privileged=true –shm-size=1g –restart always -v baota_www:/ WWW -v ~/wwwroot:/www/wwwroot pch18/baota

Log on to way

  • Login Address:http://{{Panel IP address}}:8888
  • Initial Account:username
  • Initial password:password

Pagoda panel command line

Enter the container:

docker exec -it baota bash
Copy the code

performbtFor interactive operations:

[root@bebc0d8e35b1 wwwroot]# bt= = = = = = = = = = = = = = = pagoda panel command line = = = = = = = = = = = = = = = = = = (1) service (8) restart the panel to panel port service (9) (2) stop panel clear panel cache service (3) start the panel (10) remove the login limit (4) service overloading panel (11) Remove entry restriction (5) Change panel password (12) Remove domain name binding restriction (6) Change panel user name (13) Remove IP access restriction (7) Forcibly change MySQL password (14) View default panel information (22) Display panel error logs (15) Clear system garbage (23) Turn off BasicAuth authentication (16) Fix panel (check for errors and update panel files to latest version) (24) Turn off Google Authentication (17) Set log cutting whether to compress (25) Set whether to save historical copies of files (18) Set whether to automatically backup panel (0) Cancel = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =Copy the code

The advanced configuration

  1. After logging in to the panel, change the user name and password of the panel. You are advised to change the port and security entrance of the panel.
  2. To update, you can use the update function provided by the panel.

Backup the pagoda panel container

If we migrate, we don’t need to repeat the above installation and configuration steps, just use the script I provided:

curl -fsSL https://youngjuning.js.org/shell/baota/backup.sh | sh
Copy the code

The baota.tar package will be backed up to the current directory, uploaded to the new server and loaded into the container:

docker load -i baota.tar
Copy the code

Recovery container:

curl -fsSL https://youngjuning.js.org/shell/baota/restore.sh | sh
Copy the code

Known issues

  1. In some machine initialization environments, some ports may be occupied. For example, port 80 is occupiednetstat -lnp|grep 80View the process PID, and then usekill -9 XXXXEnd the process (XXXX is the pid of the process).
  2. If you have installed nginx, uninstall it firstcurl -fsSL https://youngjuning.js.org/shell/nginx/uninstall.sh | sh