-
-
Notifications
You must be signed in to change notification settings - Fork 209
/
action.yml
92 lines (92 loc) · 3.34 KB
/
action.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
name: 'Publish Docker'
author: 'Lars Gohr'
branding:
icon: 'anchor'
color: 'blue'
description: 'Uses the git branch as the docker tag and pushes the container'
inputs:
name:
description: 'The name of the image you would like to push'
required: true
username:
description: 'The login username for the registry'
required: true
password:
description: 'The login password for the registry'
required: true
registry:
description: 'Use registry for pushing to a custom registry'
required: false
snapshot:
description: 'Use snapshot to push an additional image'
required: false
default_branch:
description: 'Set the default branch of your repository (default: master)'
required: false
dockerfile:
description: 'Use dockerfile when you would like to explicitly build a Dockerfile'
required: false
workdir:
description: 'Use workdir when you would like to change the directory for building'
required: false
context:
description: 'Use context when you would like to change the Docker build context.'
required: false
buildargs:
description: 'Use buildargs when you want to pass a list of environment variables as build-args'
required: false
buildoptions:
description: 'Use buildoptions when you want to configure options for building'
required: false
cache:
description: 'Use cache when you have big images, that you would only like to build partially'
required: false
tags:
description: 'Use tags when you want to bring your own tags (separated by comma)'
required: false
tag_names:
description: 'Use tag_names when you want to push tags/release by their git name'
required: false
tag_semver:
description: 'Push semver docker tags. e.g. image:1.2.3, image:1.2, image:1'
required: false
no_push:
description: 'Set no_push to true if you want to prevent the action from pushing to a registry (default: false)'
required: false
platforms:
description: 'Use platforms for building multi-arch images'
required: false
outputs:
tag:
description: 'Is the tag, which was pushed'
value: ${{ steps.docker-publish.outputs.tag }}
snapshot-tag:
description: 'Is the tag that is generated by the snapshot-option and pushed'
value: ${{ steps.docker-publish.outputs.snapshot-tag }}
digest:
description: 'Is the digest of the image, which was pushed'
value: ${{ steps.docker-publish.outputs.digest }}
runs:
using: 'composite'
steps:
- id: docker-publish
run: $GITHUB_ACTION_PATH/entrypoint.sh
shell: bash
env:
INPUT_NAME: ${{ inputs.name }}
INPUT_USERNAME: ${{ inputs.username }}
INPUT_PASSWORD: ${{ inputs.password }}
INPUT_REGISTRY: ${{ inputs.registry }}
INPUT_SNAPSHOT: ${{ inputs.snapshot }}
INPUT_DEFAULT_BRANCH: ${{ inputs.default_branch }}
INPUT_DOCKERFILE: ${{ inputs.dockerfile }}
INPUT_WORKDIR: ${{ inputs.workdir }}
INPUT_CONTEXT: ${{ inputs.context }}
INPUT_BUILDARGS: ${{ inputs.buildargs }}
INPUT_BUILDOPTIONS: ${{ inputs.buildoptions }}
INPUT_CACHE: ${{ inputs.cache }}
INPUT_TAGS: ${{ inputs.tags }}
INPUT_TAG_NAMES: ${{ inputs.tag_names }}
INPUT_TAG_SEMVER: ${{ inputs.tag_semver }}
INPUT_NO_PUSH: ${{ inputs.no_push }}
INPUT_PLATFORMS: ${{ inputs.platforms }}