-
Notifications
You must be signed in to change notification settings - Fork 1
72 lines (66 loc) · 2.01 KB
/
semantic-release.yaml
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
name: Semantic Release
on:
workflow_call:
secrets:
NPM_AUTH_TOKEN:
required: true
ACTIONS_TOKEN:
required: true
DOCKER_REGISTRY_USER:
required: true
DOCKER_REGISTRY_PASSWORD:
required: true
inputs:
image:
type: string
required: false
default: europe-docker.pkg.dev/ftcs-production/infrastructure/node-build-tools:16
git_author_name:
required: false
type: string
default: Intergiro Bot
git_author_email:
required: false
type: string
default: 97522104+igirobot@users.noreply.github.com
git_committer_name:
required: false
type: string
default: Intergiro Bot
git_committer_email:
required: false
type: string
default: 97522104+igirobot@users.noreply.github.com
jobs:
release:
name: Semantic Release
runs-on: [self-hosted, common]
container:
image: ${{ inputs.image }}
credentials:
username: ${{ secrets.DOCKER_REGISTRY_USER }}
password: ${{ secrets.DOCKER_REGISTRY_PASSWORD }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
persist-credentials: false
- name: 'Workaround permissions issue'
run: chown $(whoami):$(whoami) -R .
- name: Add NPM token
run: npm config set '//npm.intergiro.tech/:_authToken' ${NPM_AUTH_TOKEN}
env:
NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
- name: Install NPM dependencies
run: npm ci
- name: Release
env:
GITHUB_TOKEN: ${{ secrets.ACTIONS_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
GIT_AUTHOR_NAME: ${{ inputs.git_author_name }}
GIT_AUTHOR_EMAIL: ${{ inputs.git_author_email }}
GIT_COMMITTER_NAME: ${{ inputs.git_committer_name }}
GIT_COMMITTER_EMAIL: ${{ inputs.git_committer_email }}
HUSKY: "0"
run: npx --no-install semantic-release