-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
46 lines (46 loc) · 1.85 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
# action.yml
name: 'GitOps environment propagation'
description: 'Github action for environment propagation in gitops repository.'
branding:
icon: 'git-pull-request'
color: 'green'
inputs:
source_enviroment:
description: 'Source environment (e.g. staging)'
required: true
target_enviroment:
description: 'Target environment (e.g. production)'
required: true
prefix_folder:
description: 'Prefix for folder in which environment is stored(e.g. environments)'
required: true
default: 'environments'
suffix_folder:
description: 'Suffix for folder in which environment is stored(e.g. app)'
required: true
default: 'app'
secrets_promotion:
description: 'Option to promote secret(e.g. false)'
required: true
default: 'false'
runs:
using: "composite"
steps:
- run: ${{ github.action_path }}/propagate_files.sh ${{ inputs.source_enviroment }} ${{ inputs.target_enviroment }} ${{ inputs.prefix_folder }} ${{ inputs.suffix_folder }} ${{ inputs.secrets_promotion }}
shell: bash
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: Automatic ${{ inputs.source_enviroment }} to ${{ inputs.target_enviroment }} propagation
committer: GitHub <[email protected]>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
signoff: false
branch: ${{ inputs.source_enviroment }}-to-${{ inputs.target_enviroment }}-propagation
delete-branch: true
title: '[${{ inputs.target_enviroment }}] ${{ inputs.source_enviroment }} to ${{ inputs.target_enviroment }} propagation'
body: |
Update of manifest files. Please check if there are any changes in the <environment>-values.yaml specific file.
labels: |
propagation
${{ inputs.target_enviroment }}
draft: false