-
Notifications
You must be signed in to change notification settings - Fork 0
32 lines (30 loc) · 970 Bytes
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Release
on:
push:
tags:
- 'v*' # Push events to matching v*, i.e. v6.1.1, v7.0.0
workflow_dispatch:
inputs:
tag:
description: 'Version (name of the tag to be referenced)'
required: true
jobs:
docker:
name: DockerHub tagging
strategy:
fail-fast: false
matrix:
project: [ linux-amd64, linux-arm32v7, linux-arm64 ]
runs-on: ubuntu-20.04
steps:
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Pull latest container
run: docker pull totalcross/${{ matrix.project }}:latest
- name: Tag latest container with the same repo tag
run: docker tag totalcross/${{ matrix.project }}:latest totalcross/${{ matrix.project }}:${GITHUB_REF##*/}
- name: Push the new tag
run: docker push totalcross/${{ matrix.project }}:${GITHUB_REF##*/}