-
Notifications
You must be signed in to change notification settings - Fork 0
56 lines (45 loc) · 1.41 KB
/
toolbox.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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: toolbox Docker Image CI
on:
push:
branches: [ master ]
paths:
- toolbox/**
- .github/workflows/toolbox.yml
pull_request:
branches: [ master ]
paths:
- toolbox/**
- .github/workflows/toolbox.yml
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Get current date
uses: srfrnk/current-time@master
id: current-date
with:
format: YYYYMMDD
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
- name: Push to Docker Hub
uses: docker/build-push-action@v2
with:
context: ./toolbox
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
push: true
tags: |
${{ secrets.DOCKERHUB_USERNAME }}/toolbox:latest
#${{ secrets.DOCKERHUB_USERNAME }}/toolbox:${{ steps.current-date.outputs.formattedTime }}
- name: Docker Hub Description
uses: peter-evans/dockerhub-description@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
repository: ${{ secrets.DOCKERHUB_USERNAME }}/toolbox
short-description: 'toolbox docker image based on Alpine Linux.'
readme-filepath: ./toolbox/README.md