audit fix #33
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: ghcr push | |
on: | |
push: | |
branches: ['next'] | |
paths-ignore: ['**/*.md', '**/*.yml'] | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: ${{ github.repository }} | |
jobs: | |
build-and-push-image: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: get-npm-version | |
id: package-version | |
uses: martinbeentjes/npm-get-version-action@main | |
- name: Log in to the Container registry | |
uses: docker/login-action@v2.0.0 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build and push | |
uses: docker/build-push-action@v3.0.0 | |
with: | |
context: . | |
push: true | |
tags: | | |
ghcr.io/sipcapture/pastash:latest | |
ghcr.io/sipcapture/pastash:${{ steps.package-version.outputs.current-version}} |