Workflow file for this run
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: Testing & Building Notification Service Go (Gin) | |
on: | |
release: | |
types: | |
- created | |
- edited | |
env: | |
IMAGE_NAME: notification | |
DOCKER_TOKEN: dckr_pat_yvsyLXV6TNNj6a4R_wR44syesmU | |
jobs: | |
# test: | |
# runs-on: ubuntu-latest | |
# steps: | |
# - uses: actions/checkout@v3 | |
# - name: Set up Go | |
# uses: actions/setup-go@v4 | |
# with: | |
# go-version: '1.22.1' | |
# - name: Download Dependencies | |
# run : go mod download | |
# - name: Test | |
# run: go test -v ./test/unit/... | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Login To Docker Hub | |
run: docker login -u madaurus -p ${{env.DOCKER_TOKEN}} | |
- name: Build and push image to ACR | |
run: | | |
ls ; docker build -t madaurus/${{ env.IMAGE_NAME }}:${{ github.event.release.tag_name }} . | |
- name: Push the Image | |
run: | | |
docker push madaurus/${{ env.IMAGE_NAME}}:${{ github.event.release.tag_name }} |