-
Notifications
You must be signed in to change notification settings - Fork 8
34 lines (29 loc) · 1004 Bytes
/
publish-tools.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
33
34
name: Publish the cargo-container-tools
on:
push:
tags:
- cargo-container-tools-*
jobs:
publish-requested-tag:
name: Publish denzp/cargo-container-tools
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v1
- name: Print docker info
run: docker info
- name: Login to Docker Hub Registry
run: docker login --username $DOCKER_USERNAME --password $DOCKER_PASSWORD
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
- name: Installing buildx
run: .ci/install-buildx.sh
- name: Build and push the image
env:
TAG: ${{ github.ref }}
run: >-
docker buildx build
--push -f cargo-container-tools/Cargo.toml .
--tag denzp/cargo-container-tools:${TAG#"refs/tags/cargo-container-tools-"}
--cache-from type=registry,ref=denzp/cargo-container-tools:cache