walle 2.0 瓦力
walle 让用户代码发布终于可以不只能选择 jenkins!支持各种web代码发布,php、java、python、go等代码的发布、回滚可以通过web来一键完成。
Walle安装
本次安装采用docker-compose安装,需先下载docker与docker-compose。
1.在docker-compose.yml同级目录新建walle.env,连接数据库MYSQL_USER默认使用root,如需使用其他用户,需自建用户更改walle.env文件。
// An highlighted block
# Set MySQL/Rails environment
MYSQL_USER=root
MYSQL_PASSWORD=yourpasswd
MYSQL_DATABASE=walle
MYSQL_ROOT_PASSWORD=yourpasswd
MYSQL_HOST=db
MYSQL_PORT=3306
2.创建docker-compose.yml文件
// An highlighted block
version: "3"
services:
web:
image: alenx/walle-web:2.1
container_name: walle-nginx
hostname: nginx-web
ports:
# 如果宿主机80端口被占用,可自行修改为其他port(>=1024)
# 0.0.0.0:要绑定的宿主机端口:docker容器内端口80
- "888:80"
depends_on:
- python
networks:
- walle-net
restart: always
python:
image: alenx/walle-python:2.1
container_name: walle-python
hostname: walle-python
env_file:
# walle.env需和docker-compose在同级目录
- ./walle.env
command: bash -c "cd /opt/walle_home/ && /bin/bash admin.sh migration && python waller.py"
expose:
- "5000"
volumes:
- /opt/walle_home/plugins/:/opt/walle_home/plugins/
- /opt/walle_home/codebase/:/opt/walle_home/codebase/
- /opt/walle_home/logs/:/opt/walle_home/logs/
- /root/.ssh:/root/.ssh/
depends_on:
- db
networks:
- walle-net
restart: always
db:
image: mysql
container_name: walle-mysql
hostname: walle-mysql
security_opt:
- seccomp:unconfined
env_file:
- ./walle.env
command: [ '--default-authentication-plugin=mysql_native_password', '--character-set-server=utf8mb4', '
--collation-server=utf8mb4_unicode_ci'] ports:
- "3307:3306"
expose:
- "3306"
volumes:
- /opt/data-walle/mysql:/var/lib/mysql
networks:
- walle-net
restart: always
networks:
walle-net:
driver: bridge
3.一键启动并输出日志
# docker-compose up -d && docker-compose logs -f
出现报错,这是mysql没有初始化完,就启动了python-server,运行docker-compose down之后再docker-compose up一次就可以了。
4.部署成功之后,打开浏览器访问http://ip:port(nginx端口)
初始登录账号如下:
超管:super@walle-web.io \ Walle123
所有者:owner@walle-web.io \ Walle123
负责人:master@walle-web.io \ Walle123
开发者:developer@walle-web.io \ Walle123
访客:reporter@walle-web.io \ Walle123
以身份所有者登录:
部署完成!