2024-04-12 14:07:00 +08:00
|
|
|
name: Build image
|
|
|
|
on: [push]
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-04-12 14:24:19 +08:00
|
|
|
- name: Checkout
|
2024-05-12 16:14:24 +08:00
|
|
|
uses: actions/checkout@v4
|
2024-04-12 14:22:34 +08:00
|
|
|
- name: build
|
2024-04-13 09:37:11 +08:00
|
|
|
run: docker build -t ${{ vars.DOCKER_REGISTRY }}/${{ vars.IMAGE_NAME }}:1.3 -f Dockerfile .
|
|
|
|
- name: tag
|
2024-04-13 10:57:17 +08:00
|
|
|
run: docker tag ${{ vars.DOCKER_REGISTRY }}/${{ vars.IMAGE_NAME }}:1.3 ${{ vars.DOCKER_REGISTRY }}/${{ vars.IMAGE_NAME }}:latest
|
2024-04-13 09:37:11 +08:00
|
|
|
- name: push 1.3
|
|
|
|
run: docker push ${{ vars.DOCKER_REGISTRY }}/${{ vars.IMAGE_NAME }}:1.3
|
|
|
|
- name: push latest
|
2024-04-12 14:28:23 +08:00
|
|
|
run: docker push ${{ vars.DOCKER_REGISTRY }}/${{ vars.IMAGE_NAME }}:latest
|