devilbox/.github/workflows/ci-smoke-linux.yml
2020-11-07 11:17:59 +01:00

216 lines
5.1 KiB
YAML

---
# -------------------------------------------------------------------------------------------------
# Job Name
# -------------------------------------------------------------------------------------------------
name: Linux
# -------------------------------------------------------------------------------------------------
# When to run
# -------------------------------------------------------------------------------------------------
on:
# Runs on Pull Requests
pull_request:
# Runs on master Branch and Tags
push:
branches:
- master
tags:
- '[0-9]+.[0-9]+*'
# -------------------------------------------------------------------------------------------------
# What to run
# -------------------------------------------------------------------------------------------------
jobs:
smoke_linux:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php:
- "5.3"
- "5.4"
- "5.5"
- "5.6"
- "7.0"
- "7.1"
- "7.2"
- "7.3"
- "7.4"
- "8.0"
- "8.1"
httpd:
- "apache-2.2"
- "apache-2.4"
- "nginx-stable"
- "nginx-mainline"
name: "[PHP ${{ matrix.php }}] vs [${{ matrix.httpd }}]"
steps:
# ------------------------------------------------------------
# Checkout repository
# ------------------------------------------------------------
- name: Checkout repository
uses: actions/checkout@v1
- name: Show environment
shell: bash
run: |
env
- name: Show network
shell: bash
run: |
netstat -an || true
ss -tlun || true
- name: Show Docker version
shell: bash
run: |
docker version
# ------------------------------------------------------------
# Setup
# ------------------------------------------------------------
- name: Configure
shell: bash
run: |
cd .tests/
# Set the two candidates to test against
make configure KEY=PHP_SERVER VAL=${PHP}
make configure KEY=HTTPD_SERVER VAL=${HTTPD}
# 3306 is taken, so chose another one
make configure KEY=HOST_PORT_MYSQL VAL=3307
env:
PHP: ${{ matrix.php }}
HTTPD: ${{ matrix.httpd }}
- name: Pull images
shell: bash
run: |
cd .tests/
make pull
- name: Startup
shell: bash
run: |
cd .tests/
make start
- name: Docker logs
shell: bash
run: |
cd .tests/
make logs
# ------------------------------------------------------------
# Run tests
# ------------------------------------------------------------
- name: Test Modules
shell: bash
run: |
cd .tests/
make test-smoke-modules
if: success() || failure()
- name: Test Config
shell: bash
run: |
cd .tests/
make test-smoke-config
if: success() || failure()
- name: Test Intranet
shell: bash
run: |
cd .tests/
make test-smoke-intranet
if: success() || failure()
- name: Test Vendors
shell: bash
run: |
cd .tests/
make test-smoke-vendors
if: success() || failure()
- name: Test Vhosts
shell: bash
run: |
cd .tests/
make test-smoke-vhosts
if: success() || failure()
- name: Test Reverse Proxy
shell: bash
run: |
cd .tests/
make test-smoke-rproxies
if: success() || failure()
- name: Test SSL
shell: bash
run: |
cd .tests/
make test-smoke-ssl
if: success() || failure()
- name: Test Bind
shell: bash
run: |
cd .tests/
make test-smoke-bind
if: success() || failure()
- name: Test Autostart
shell: bash
run: |
cd .tests/
make test-smoke-autostart
if: success() || failure()
- name: "Test Framework: CakePHP"
shell: bash
run: |
cd .tests/
make test-smoke-framework-cakephp
if: success() || failure()
- name: "Test Framework: Drupal"
shell: bash
run: |
cd .tests/
make test-smoke-framework-drupal
if: success() || failure()
- name: "Test Framework: Wordpress"
shell: bash
run: |
cd .tests/
make test-smoke-framework-wordpress
if: success() || failure()
- name: "Test Container"
shell: bash
run: |
cd .tests/
make test-smoke-container
if: success() || failure()
# ------------------------------------------------------------
# Finish
# ------------------------------------------------------------
- name: "Finish: Docker logs"
shell: bash
run: |
cd .tests/
make logs
if: success() || failure()