place TAG variable to >> $GITHUB_ENV #76
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker Image CI | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Show Java Version | |
run: java -version | |
- name: Build the Docker image | |
run: docker build . --file Dockerfile --tag gitbeaver/release:latest | |
- name: Login to Docker Hub | |
uses: docker/login-action@v2 | |
with: | |
username: gitbeaver | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Push docker image to docker.io | |
run: docker push gitbeaver/release:latest | |
- name: Make docu | |
run: sh doc/createDocumentation.sh | |
- name: Add docu | |
run: git add doc | |
- name: Set user name | |
run: git config user.name "Documentation update" | |
- name: Set user email | |
run: git config user.email "[email protected]" | |
- name: Commit docu | |
run: git commit --allow-empty -m "Updated docu" | |
- name: Git push | |
run: git push | |