SoFunction
Updated on 2025-03-09

How to install Zen by Docker

Docker installation Zen path

1. Check whether the server has a Zen container

docker ps -a

All containers can be viewed.

2. Download Zen Taoist mirror from the docker library

If there is no Zen container or Zen mirror on the server

Download the image from the docker library

sudo docker pull /app/zentao:18.5 

3. Install Zen Taoism and run mirror

Create a docker network driver

sudo docker network create --subnet=[ipscope] [Network driver name] 

IP range: For example, 172.172.172.0/24 means that IP can specify a range from 172.172.172.1 to 172.172.172.254;

Network driver name: The created network driver name can be specified at will;

For example:

sudo docker network create --subnet=172.172.172.0/24 zentaonet 

Start the Zen container:

sudo docker run \
--name [Container name] \
-p [Host Port]:80 \
--network=[Network driver name] \
--ip [containerIP] \
--mac-address [macaddress] \
-v [Host Zen Directory]:/data \
-e MYSQL_INTERNAL=true \
-d /app/zentao:[Mirror tags] 

Parameter description:

  • Container name: The name of the started container, you can specify it at will;
  • Host port: The host port is a web access port;
  • Network driver name: the network driver name zentaonet created above;
  • Container IP: Select a fixed IP for the container within the network driver range;
  • mac address: Specify a fixed mac address, the recommended range is 02:42:ac:11:00:00 to 02:42:ac:11:ff:ff;
  • Host Zen Directory: Must be specified to facilitate the persistence of attachments and other data;
  • MYSQL_INTERNAL=true: Enable the container built-in MySQL, the default user name is root, and the password is 123456
  • Mirror tag: Zen version

Check whether the container starts successfully:

# View Zen containerdocker ps | grep zentao
# View Zen Container Logdocker logs -f zentao 

4. Landing in the Zen Path

Enter: http://server ip:[d port] in the browser to access the Zen container. If the port 80 of the Zen Tao container maps other ports of the host instead of port 80, then change the port number of the browser address bar to the corresponding host port.

  • Username: admin
  • Password: 123456

You need to change your password for the first login:

New passwords for upper and lower case and digits are recommended, such as: Testing123

Summarize

The above is personal experience. I hope you can give you a reference and I hope you can support me more.