2020-02-26 16:54:14 +00:00
|
|
|
name: ci
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
|
|
|
|
jobs:
|
2020-12-07 12:41:12 +00:00
|
|
|
codespell:
|
|
|
|
name: codespell
|
|
|
|
runs-on: ubuntu-20.04
|
2020-02-26 16:54:14 +00:00
|
|
|
steps:
|
2020-12-07 12:41:12 +00:00
|
|
|
- name: Checkout Code
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Codespell
|
|
|
|
uses: codespell-project/actions-codespell@master
|
2020-02-26 23:33:46 +00:00
|
|
|
with:
|
2020-12-07 12:41:12 +00:00
|
|
|
skip: .git
|
|
|
|
check_filenames: true
|
|
|
|
check_hidden: true
|
2020-02-26 23:33:46 +00:00
|
|
|
|
2020-03-07 03:19:55 +00:00
|
|
|
lint-docker-compose-file:
|
2020-12-07 12:41:12 +00:00
|
|
|
runs-on: ubuntu-20.04
|
2020-03-07 03:19:55 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
- name: lint zammad docker-compose file
|
|
|
|
run: docker-compose config
|
|
|
|
|
2020-12-07 12:41:12 +00:00
|
|
|
super-linter:
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
steps:
|
|
|
|
- name: Checkout Code
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Lint Code Base
|
|
|
|
uses: github/super-linter@v3
|
|
|
|
env:
|
|
|
|
DEFAULT_BRANCH: master
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
|
2020-03-06 17:50:38 +00:00
|
|
|
build-and-run-docker-compose:
|
2020-12-07 12:41:12 +00:00
|
|
|
needs:
|
|
|
|
- codespell
|
2020-03-07 03:19:55 +00:00
|
|
|
- lint-docker-compose-file
|
2020-12-07 12:41:12 +00:00
|
|
|
- super-linter
|
2020-03-07 12:21:46 +00:00
|
|
|
timeout-minutes: 20
|
2020-12-07 12:41:12 +00:00
|
|
|
runs-on: ubuntu-20.04
|
2020-02-26 16:54:14 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v1
|
2020-03-06 17:50:38 +00:00
|
|
|
- name: build docker containers
|
2020-12-07 12:41:12 +00:00
|
|
|
run: .github/docker-image-build.sh
|
2020-03-06 13:41:59 +00:00
|
|
|
- name: use images build by ci
|
2020-03-06 17:50:38 +00:00
|
|
|
run: sed -i -e 's#${IMAGE_REPO}:##g' -e 's#${VERSION}##g' docker-compose.yml
|
2020-02-26 23:33:46 +00:00
|
|
|
- name: run docker-compose up
|
|
|
|
run: docker-compose up --detach
|
2020-02-27 23:38:52 +00:00
|
|
|
- name: add autowizard file
|
|
|
|
run: docker cp .github/auto_wizard.json zammad-docker-compose_zammad-railsserver_1:/opt/zammad
|
2020-02-26 23:33:46 +00:00
|
|
|
- name: run tests
|
|
|
|
run: .github/tests.sh
|
2020-03-07 12:21:46 +00:00
|
|
|
|
|
|
|
run-remote-image-docker-compose:
|
2020-12-07 12:41:12 +00:00
|
|
|
needs:
|
|
|
|
- codespell
|
2020-03-07 12:21:46 +00:00
|
|
|
- lint-docker-compose-file
|
2020-12-07 12:41:12 +00:00
|
|
|
- super-linter
|
2020-03-07 12:21:46 +00:00
|
|
|
timeout-minutes: 10
|
2020-12-07 12:41:12 +00:00
|
|
|
runs-on: ubuntu-20.04
|
2020-03-07 12:21:46 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v1
|
|
|
|
- name: pull docker-compose images
|
2020-12-07 12:41:12 +00:00
|
|
|
run: docker-compose pull
|
2020-03-07 12:21:46 +00:00
|
|
|
- name: run docker-compose up
|
|
|
|
run: docker-compose up --detach
|
|
|
|
- name: add autowizard file
|
|
|
|
run: docker cp .github/auto_wizard.json zammad-docker-compose_zammad-railsserver_1:/opt/zammad
|
|
|
|
- name: run tests
|
|
|
|
run: .github/tests.sh
|