forked from VirtoCommerce/vc-storefront
-
Notifications
You must be signed in to change notification settings - Fork 0
92 lines (80 loc) · 2.83 KB
/
release-branch.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
# v3.200.5
name: Release - branch
on:
workflow_dispatch:
inputs:
incrementVersion:
description: 'Increment automatically minor\patch version before release created. If "none" version will not be incremented.'
required: true
default: 'none'
type: choice
options:
- none
jobs:
test:
uses: VirtoCommerce/.github/.github/workflows/[email protected]
secrets:
sonarToken: ${{ secrets.SONAR_TOKEN }}
build:
uses: VirtoCommerce/.github/.github/workflows/[email protected]
with:
uploadPackage: 'true'
uploadDocker: 'true'
eventName: ${{ github.event_name }}
imageName: 'storefront'
dockerFiles: 'https://raw.githubusercontent.com/VirtoCommerce/vc-docker/feat/net6/linux/storefront/Dockerfile'
forceVersionSuffix: 'false'
secrets:
envPAT: ${{ secrets.REPO_TOKEN }}
get-metadata:
runs-on: ubuntu-latest
env:
DOCKER_CACHE_KEY: ''
DOCKER_TAR: 'image.tar'
outputs:
dockerShortKey: ${{ steps.cache-key.outputs.dockerShortKey }}
dockerFullKey: ${{ steps.cache-key.outputs.dockerFullKey }}
packageShortKey: ${{ steps.cache-key.outputs.packageShortKey }}
packageFullKey: ${{ steps.cache-key.outputs.packageFullKey }}
dockerTar: ${{ env.DOCKER_TAR }}
changelog: ${{ steps.changelog.outputs.changelog }}
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Get Changelog
id: changelog
uses: VirtoCommerce/vc-github-actions/changelog-generator@master
- name: Get Artifact Version
uses: VirtoCommerce/vc-github-actions/get-image-version@master
id: artifactVer
- name: Get cache key
uses: VirtoCommerce/vc-github-actions/cache-get-key@master
id: cache-key
with:
runnerOs: ${{ runner.os }}
artifactName: ${{ github.event.repository.name }}
publish-docker:
needs:
[build, test, get-metadata]
uses: VirtoCommerce/.github/.github/workflows/[email protected]
with:
fullKey: ${{ needs.get-metadata.outputs.dockerFullKey }}
shortKey: '${{ needs.get-metadata.outputs.dockerShortKey }}-'
dockerTar: ${{ needs.get-metadata.outputs.dockerTar }}
publishToDocker: 'true'
secrets:
envPAT: ${{ secrets.GITHUB_TOKEN }}
dockerUser: ${{ secrets.DOCKER_USERNAME }}
dockerToken: ${{ secrets.DOCKER_TOKEN }}
publish-github-release:
needs:
[build, test, get-metadata]
uses: VirtoCommerce/.github/.github/workflows/[email protected]
with:
fullKey: ${{ needs.get-metadata.outputs.packageFullKey }}
shortKey: '${{ needs.get-metadata.outputs.packageShortKey }}-'
changeLog: '${{ needs.get-metadata.outputs.changeLog }}'
forceNuget: false
secrets:
envPAT: ${{ secrets.GITHUB_TOKEN }}