Chevereto Docker版安装

1. 下载地址

DockerHub仓库 我使用的是nmtan的镜像
作者Github 地址

2. 安装Docker

因为本次使用Docker安装Chevereto,所以首先安装Docker

  1. 常用软件安装
bash
  • 01
apt-get update && apt-get install -y wget vim
  1. 安装Docker
bash
  • 01
wget -qO- get.docker.com | bash
  1. 查看版本
bash
  • 01
docker -v
  1. 设置开机自动启动
bash
  • 01
systemctl enable docker
  1. 安装docker-compose
bash
  • 01
  • 02
  • 03
  • 04
  • 05
sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose sudo chmod +x /usr/local/bin/docker-compose docker-compose --version

3. 安装Chevereto

  1. 创建目录
bash
  • 01
  • 02
mkdir -p /root/data/docker_data/chevereto cd /root/data/docker_data/chevereto
  1. 创建docker容器
bash
  • 01
  • 02
  • 03
  • 04
  • 05
  • 06
  • 07
  • 08
  • 09
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
version: '3' services: db: image: mariadb volumes: - /root/data/docker_data/chevereto/mysql:/var/lib/mysql:rw restart: always networks: - private environment: MYSQL_ROOT_PASSWORD: chevereto_root MYSQL_DATABASE: chevereto MYSQL_USER: chevereto MYSQL_PASSWORD: chevereto chevereto: depends_on: - db image: einverne/chevereto restart: always networks: - private environment: CHEVERETO_DB_HOST: db CHEVERETO_DB_USERNAME: chevereto CHEVERETO_DB_PASSWORD: chevereto CHEVERETO_DB_NAME: chevereto CHEVERETO_DB_PREFIX: chv_ volumes: - /home/暂存/docker/chevereto:/var/www/html/images:rw ports: - 8002:80 networks: private: volumes: database: chevereto_images: