2
0
mirror of https://github.com/frappe/frappe_docker.git synced 2024-11-08 22:31:07 +00:00
frappe_docker/.travis.yml
2020-05-02 00:21:56 +05:30

160 lines
6.7 KiB
YAML

sudo: required
dist: bionic
services:
- docker
before_install:
- if [[ "$BUILD" != "development" ]]; then
echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin;
sudo apt-get update && sudo apt-get -y install git;
fi
- if [[ $BUILD == "development" ]];then
sudo apt-get update && sudo apt-get -y install docker-compose;
fi
- chmod u+x ./travis.py
after_success:
- docker --version
jobs:
include:
- stage: "Build Frappe bench development environment (latest)"
if: branch = develop AND type != pull_request
script:
- docker build -t frappe/bench:latest -f build/bench/Dockerfile .
- docker push frappe/bench:latest
- stage: "Frappe (edge)"
if: branch = develop AND type != pull_request
script:
- ./travis.py frappe --worker --tag edge
- ./travis.py frappe --worker --tag develop --tag-only
- stage: "Frappe (edge)"
if: branch = develop AND type != pull_request
script:
- ./travis.py frappe --nginx --tag edge
- ./travis.py frappe --nginx --tag develop --tag-only
- stage: "Frappe (edge)"
if: branch = develop AND type != pull_request
script:
- ./travis.py frappe --socketio --tag edge
- ./travis.py frappe --socketio --tag develop --tag-only
- stage: "ERPNext (edge)"
if: branch = develop AND type != pull_request
script:
- ./travis.py erpnext --worker --tag edge
- ./travis.py erpnext --worker --tag develop --tag-only
- stage: "ERPNext (edge)"
if: branch = develop AND type != pull_request
script:
- ./travis.py erpnext --nginx --tag edge
- ./travis.py erpnext --nginx --tag develop --tag-only
- stage: "Frappe (v13-beta)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --worker --git-version 13-beta
- ./travis.py frappe --worker --tag v13-beta --tag-only
- ./travis.py frappe --worker --tag version-13-beta --tag-only
- stage: "Frappe (v13-beta)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --nginx --git-version 13-beta
- ./travis.py frappe --nginx --tag v13-beta --tag-only
- ./travis.py frappe --nginx --tag version-13-beta --tag-only
- stage: "Frappe (v13-beta)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --socketio --git-version 13-beta
- ./travis.py frappe --socketio --tag v13-beta --tag-only
- ./travis.py frappe --socketio --tag version-13-beta --tag-only
- stage: "ERPNext (v13-beta)"
if: branch = master AND type != pull_request
script:
- ./travis.py erpnext --worker --git-version 13-beta
- ./travis.py erpnext --worker --tag v13-beta --tag-only
- ./travis.py erpnext --worker --tag version-13-beta --tag-only
- stage: "ERPNext (v13-beta)"
if: branch = master AND type != pull_request
script:
- ./travis.py erpnext --nginx --git-version 13-beta
- ./travis.py erpnext --nginx --tag v13-beta --tag-only
- ./travis.py erpnext --nginx --tag version-13-beta --tag-only
- stage: "Frappe (v12)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --worker --git-version 12
- ./travis.py frappe --worker --tag v12 --tag-only
- ./travis.py frappe --worker --tag version-12 --tag-only
- stage: "Frappe (v12)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --nginx --git-version 12
- ./travis.py frappe --nginx --tag v12 --tag-only
- ./travis.py frappe --nginx --tag version-12 --tag-only
- stage: "Frappe (v12)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --socketio --git-version 12
- ./travis.py frappe --socketio --tag v12 --tag-only
- ./travis.py frappe --socketio --tag version-12 --tag-only
- stage: "ERPNext (v12)"
if: branch = master AND type != pull_request
script:
- ./travis.py erpnext --worker --git-version 12
- ./travis.py erpnext --worker --tag v12 --tag-only
- ./travis.py erpnext --worker --tag version-12 --tag-only
- stage: "ERPNext (v12)"
if: branch = master AND type != pull_request
script:
- ./travis.py erpnext --nginx --git-version 12
- ./travis.py erpnext --nginx --tag v12 --tag-only
- ./travis.py erpnext --nginx --tag version-12 --tag-only
- stage: "Frappe (v11)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --worker --git-version 11
- ./travis.py frappe --worker --tag v11 --tag-only
- ./travis.py frappe --worker --tag version-11 --tag-only
- stage: "Frappe (v11)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --nginx --git-version 11
- ./travis.py frappe --nginx --tag v11 --tag-only
- ./travis.py frappe --nginx --tag version-11 --tag-only
- stage: "Frappe (v11)"
if: branch = master AND type != pull_request
script:
- ./travis.py frappe --socketio --git-version 11
- ./travis.py frappe --socketio --tag v11 --tag-only
- ./travis.py frappe --socketio --tag version-11 --tag-only
- stage: "ERPNext (v11)"
if: branch = master AND type != pull_request
script:
- ./travis.py erpnext --worker --git-version 11
- ./travis.py erpnext --worker --tag v11 --tag-only
- ./travis.py erpnext --worker --tag version-11 --tag-only
- stage: "ERPNext (v11)"
if: branch = master AND type != pull_request
script:
- ./travis.py erpnext --nginx --git-version 11
- ./travis.py erpnext --nginx --tag v11 --tag-only
- ./travis.py erpnext --nginx --tag version-11 --tag-only
- stage: "Build and test edge images"
if: type = pull_request
before_install:
- sudo apt-get update && sudo apt-get -y install docker-compose
script:
- docker build -t frappe/frappe-socketio:edge -f build/frappe-socketio/Dockerfile .
- docker build -t frappe/frappe-worker:develop -f build/frappe-worker/Dockerfile .
- docker build -t frappe/erpnext-worker:edge -f build/erpnext-worker/Dockerfile .
- docker build -t frappe/frappe-nginx:develop -f build/frappe-nginx/Dockerfile .
- docker build -t frappe/erpnext-nginx:edge -f build/erpnext-nginx/Dockerfile .
- ./tests/docker-test.sh
- stage: "Pull and test edge images"
if: branch = develop AND type != pull_request
before_install:
- sudo apt-get update && sudo apt-get -y install docker-compose
script:
- ./tests/docker-test.sh