Skip to content

Commit

Permalink
Update test.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
odidev committed Apr 16, 2021
1 parent 6efeeaa commit b071913
Showing 1 changed file with 30 additions and 10 deletions.
40 changes: 30 additions & 10 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,38 @@
name: Test image build
name: ci

on:
pull_request:
branches: [ master ]
push:
branches:
- master
tags:
- v*

jobs:
build:
name: Build docker image

publish:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Build
run: docker build .
- uses: actions/checkout@v2
- name: Prepare
id: prepare
run: |
TAG=${GITHUB_REF##*/}
echo ::set-output name=tag_name::${TAG}
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login do docker.io
run: docker login -u odidev -p ${{ secrets.DOCKER_TOKEN }}
- name: build and publish image
id: docker_build
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: |
odidev/dcind:${{ steps.prepare.outputs.tag_name }}
odidev/dcind:latest

0 comments on commit b071913

Please sign in to comment.