actions-gh-pages/.github/workflows/docker-image-ci.yml
Shohei Ueda 9dbd791001
Release v2.0.0 (#10)
Changes for peaceiris/actions-gh-pages

* update: yaml example of GitHub Actions v2 settings for MkDocs, close #8
* revert: support ACTIONS_DEPLOY_KEY (ssh deploy) again
* upgrade: Hugo to v0.58.0 at example yaml
* remove: steps if statement from example yaml, close #12

Changes for this repository

* gha: add lint job (shellcheck and hadolint)
* gha: remove tag filter
* gha: remove steps if statement, close #12
* gha: add action.yml
* fix: FUNDING.yml
2019-09-05 23:07:49 +09:00

48 lines
1.2 KiB
YAML

name: docker image ci
on:
push:
branches:
- master
- 'release-v*'
jobs:
test:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@master
- name: build
env:
DOCKER_IMAGE: docker.pkg.github.com/${{ github.repository }}/action:latest
run: |
docker build . --file Dockerfile --tag ${DOCKER_IMAGE} ||
(echo -e "\e[31m[${GITHUB_WORKFLOW}] failed to build\e[m" && exit 1)
# - name: push latest image
# if: endsWith(github.ref, 'master')
# env:
# DOCKER_IMAGE: docker.pkg.github.com/${{ github.repository }}/action:latest
# PKG_GITHUB_TOKEN: ${{ secrets.PKG_GITHUB_TOKEN }}
# run: |
# echo ${PKG_GITHUB_TOKEN} | docker login docker.pkg.github.com -u ${GITHUB_ACTOR} --password-stdin &&
# docker push ${DOCKER_IMAGE} &&
# docker logout
shellcheck:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@master
- name: shellcheck
run: shellcheck ./entrypoint.sh
hadolint:
runs-on: macOS-10.14
steps:
- uses: actions/checkout@master
- name: hadolint
run: |
brew install hadolint
hadolint ./Dockerfile