Skip to content

Commit

Permalink
Update docker-image.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
nfyxhan authored Aug 22, 2023
1 parent 3df8b4e commit e53ac50
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: Docker Image CI

env:
REGISTRY: ${{ vars.REGISTRY }}
REGISTRY_USERNAME: ${{ secrets.REGISTRY_USERNAME }}
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }}
FULL_IMAGE: ${{ vars.REGISTRY }}/tc-ocr:v${{ github.sha }}
REGISTRY: ${{ vars.REGISTRY }}
FULL_IMAGE: ${{ vars.REGISTRY }}/${{ github.repository }}:v${{ github.sha }}

on:
push:
Expand All @@ -21,19 +21,15 @@ jobs:
- name: Login to Ali Docker
uses: docker/login-action@v2
with:
registry: ${{ vars.REGISTRY }}
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}
registry: ${{ env.REGISTRY }}
username: ${{ env.REGISTRY_USERNAME }}
password: ${{ env.REGISTRY_PASSWORD }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
context: .
push: true
tags: ${{ env.FULL_IMAGE }}
- name: Tests
uses: cloudposse/github-action-docker-compose-test-run@main
with:
file: test/docker-compose.yml
service: tr-ocr
command: test/unit-tests.sh
env:
FULL_IMAGE: ${{ env.FULL_IMAGE }}

0 comments on commit e53ac50

Please sign in to comment.