diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 0000000..1f05949 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,97 @@ +--- +name: ci + +"on": + pull_request: + push: + branches: + - master + +jobs: + delivery: + runs-on: ubuntu-latest + steps: + - name: Check out code + uses: actions/checkout@main + - name: Run Chef Delivery + uses: actionshub/chef-delivery@main + env: + CHEF_LICENSE: accept-no-persist + + yamllint: + runs-on: ubuntu-latest + steps: + - name: Check out code + uses: actions/checkout@main + - name: Run yaml Lint + uses: actionshub/yamllint@main + + mdl: + runs-on: ubuntu-latest + steps: + - name: Check out code + uses: actions/checkout@main + - name: Run Markdown Lint + uses: actionshub/markdownlint@main + + dokken: + needs: [mdl, yamllint, delivery] + runs-on: ubuntu-latest + strategy: + matrix: + os: + - 'centos-7' + - 'centos-8' + - 'debian-9' + - 'debian-10' + - 'opensuse-leap-15' + - 'ubuntu-1804' + suite: + - 'basic-site' + - 'default' + - 'mod-auth-cas' + - 'mod-php' + - 'module-template' + - 'mod-wsgi' + - 'pkg-name' + - 'ports' + - 'ssl' + exclude: + - os: debian-9 + suite: pkg-name + - os: debian-10 + suite: pkg-name + - os: centos-8 + suite: pkg-name + - os: ubuntu-1804 + suite: pkg-name + - os: opensuse-leap-15 + suite: pkg-name + fail-fast: false + + steps: + - name: Check out code + uses: actions/checkout@main + - name: Install Chef + uses: actionshub/chef-install@main + - name: Dokken + uses: actionshub/kitchen-dokken@main + env: + CHEF_LICENSE: accept-no-persist + KITCHEN_LOCAL_YAML: kitchen.dokken.yml + with: + suite: ${{ matrix.suite }} + os: ${{ matrix.os }} + - name: Print debug output on failure + if: failure() + run: | + set -x + sudo journalctl -l --since today + KITCHEN_LOCAL_YAML=kitchen.dokken.yml /usr/bin/kitchen exec ${{ matrix.suite }}-${{ matrix.os }} -c "journalctl -l" + + final: + needs: [dokken] + runs-on: ubuntu-latest + steps: + - name: Check out code + uses: actions/checkout@main