跳转到主要内容

rancher安装手册

version: "3"
services:
  rancher-2.0:
    image: rancher/rancher:v2.5.17
    restart: always
    ports:
#      - 8080:8080
      - 8000:443
    privileged: true
    volumes:
      - ./data:/var/lib/rancher/
  mysql:
    image: mysql:5.7 # 一定要写清楚版本号,不同版本之间会出现不兼容
    privileged: true
    restart: always # 自动重启
    ports:
      - 33306:3306
    volumes:
      - ./mysql:/var/lib/mysql # 文件存储
    environment:
      - TZ=Asia/Shanghai
      - MYSQL_ROOT_PASSWORD=<set your mysql root password> # root密码