ci: updated action #60
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: Publish | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
build-and-publish-image: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
- name: Install Dependencies | |
run: npm ci | |
- name: Release | |
env: | |
GITHUB_TOKEN: ${{ secrets.ACTION_TOKEN }} | |
run: npx semantic-release | |
- name: Authenticate Github Container Registry | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.ACTION_TOKEN }} | |
- name: Build and Publish the Docker Image | |
run: | | |
docker build -t ghcr.io/abi-interoperability-thesis/preprocessing-webservice:latest . | |
docker push ghcr.io/abi-interoperability-thesis/preprocessing-webservice:latest | |
- name: '♻️ cleanup' | |
run: | | |
echo ${{ env.RELEASE_TAG }} | |
echo ${{ env.RELEASE_VERSION }} |