Skip to content

release

release #90

Workflow file for this run

---
name: release
on:
create:
tags:
- '**'
env:
DOCKER_REPO: litmuschaos
DOCKER_IMAGE: ansible-runner
defaults:
run:
shell: bash
jobs:
push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set Tag
run: |
TAG="${GITHUB_REF#refs/*/}"
echo "TAG=${TAG}" >> $GITHUB_ENV
echo "RELEASE_TAG=${TAG}" >> $GITHUB_ENV
- name: Print Tag info
run: |
echo "RELEASE TAG: ${RELEASE_TAG}"
echo "${RELEASE_TAG}" > ${{ github.workspace }}/tag.txt
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: all
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
with:
version: latest
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DNAME }}
password: ${{ secrets.DPASS }}
- name: Build and push
uses: docker/build-push-action@v2
env:
RELEASE_TAG: ${{ env.RELEASE_TAG }}
with:
push: true
file: build/ansible-runner/Dockerfile
platforms: linux/amd64
tags: litmuschaos/ansible-runner:${{ env.RELEASE_TAG }},litmuschaos/ansible-runner:latest