Skip to content

Commit 9d70b72

Browse files
authored
fix: release automation (#10)
1 parent ebcd772 commit 9d70b72

File tree

14 files changed

+318
-12
lines changed

14 files changed

+318
-12
lines changed

.editorconfig

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
indent_style = space
6+
indent_size = 4
7+
insert_final_newline = true
8+
trim_trailing_whitespace = true
9+
end_of_line = lf
10+
max_line_length = 160
11+
12+
[*.{yaml,yml}]
13+
indent_size = 2
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
name: 🐞 Bug
2+
description: Something is not working as indended.
3+
labels: [🐞 bug]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
Thanks for taking the time to fill out this bug report!
9+
10+
Before you submit this issue, please make sure you have read the documentation and searched for similar issues.
11+
If you have done that, please fill out the template below.
12+
13+
- type: textarea
14+
attributes:
15+
label: Current Behavior
16+
description: A concise description of what you're experiencing.
17+
placeholder: |
18+
When I do <X>, <Y> happens and I see the error message attached below:
19+
```...```
20+
validations:
21+
required: true
22+
23+
- type: textarea
24+
attributes:
25+
label: Expected Behavior
26+
description: A concise description of what you expected to happen.
27+
placeholder: When I do <X>, <Z> should happen instead.
28+
validations:
29+
required: true
30+
31+
- type: textarea
32+
attributes:
33+
label: Steps To Reproduce
34+
description: Steps to reproduce the behavior.
35+
placeholder: |
36+
1. In this environment...
37+
2. With this config...
38+
3. Run '...'
39+
4. See error...
40+
render: Markdown
41+
validations:
42+
required: false
43+
44+
- type: markdown
45+
attributes:
46+
value:
47+
Please not that openvpn-auth-oauth2 requires an OpenVPN server version
48+
2.6.2 or higher.
49+
50+
- type: textarea
51+
attributes:
52+
label: Environment
53+
description: |
54+
examples:
55+
- **openvpn-auth-oauth2 Version**: 1.5.1
56+
- **OpenVPN Server Version**: 2.6.2
57+
- **Server OS**: Linux
58+
- **OpenVPN Client (flavor, OS)**: Tunnelblick 4.0.0beta10 / MacOS
59+
- **OIDC Provider**: Entra ID
60+
value: |
61+
- openvpn-auth-oauth2 Version:
62+
- OpenVPN Server Version:
63+
- Server OS:
64+
- OpenVPN Client (flavor, OS):
65+
- OIDC Provider:
66+
validations:
67+
required: true
68+
69+
- type: textarea
70+
attributes:
71+
label: openvpn-auth-oauth2 logs
72+
description: |
73+
Log of openvpn-auth-oauth2. Output of `journalctl -flu openvpn-auth-oauth2` and `dmesg | grep openvpn`, if openvpn-auth-oauth2 is installed as linux package.
74+
⚠️ Without proving logs, I unable to assist here. ⚠️
75+
render: shell
76+
validations:
77+
required: true
78+
79+
- type: textarea
80+
attributes:
81+
label: openvpn server logs
82+
description: |
83+
Log of openvpn server
84+
render: shell
85+
validations:
86+
required: false
87+
88+
- type: textarea
89+
attributes:
90+
label: Anything else?
91+
description: |
92+
Links? References? Anything that will give us more context about the issue you are encountering!
93+
94+
Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in.
95+
validations:
96+
required: false
97+
98+
- type: checkboxes
99+
id: documentation
100+
attributes:
101+
label: Preflight Checklist
102+
options:
103+
- required: true
104+
#language=markdown
105+
label: |
106+
I could not find a solution in the [documentation](https://github.com/jkroepke/openvpn-auth-oauth2/wiki),
107+
the [FAQ](https://github.com/jkroepke/openvpn-auth-oauth2/wiki/FAQ), the existing issues or discussions.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blank_issues_enabled: false
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: ✨ Enhancement / Feature / Task
2+
description: Some feature is missing or incomplete.
3+
labels: [✨ enhancement]
4+
body:
5+
- type: textarea
6+
attributes:
7+
label: Problem Statement
8+
description:
9+
Without specifying a solution, describe what the project is missing
10+
today.
11+
placeholder: |
12+
The rotating project logo has a fixed size and color.
13+
There is no way to make it larger and more shiny.
14+
validations:
15+
required: false
16+
- type: textarea
17+
attributes:
18+
label: Proposed Solution
19+
description: Describe the proposed solution to the problem above.
20+
placeholder: |
21+
- Implement 2 new flags CLI: ```--logo-color=FFD700``` and ```--logo-size=100```
22+
- Let these flags control the size of the rotating project logo.
23+
validations:
24+
required: false
25+
- type: textarea
26+
attributes:
27+
label: Additional information
28+
placeholder: |
29+
We considered adjusting the logo size to the phase of the moon, but there was no
30+
reliable data source in air-gapped environments.
31+
validations:
32+
required: false
33+
- type: textarea
34+
attributes:
35+
label: Acceptance Criteria
36+
placeholder: |
37+
- [ ] As a user, I can control the size of the rotating logo using a CLI flag.
38+
- [ ] As a user, I can control the color of the rotating logo using a CLI flag.
39+
- [ ] Defaults are reasonably set.
40+
- [ ] New settings are appropriately documented.
41+
- [ ] No breaking change for current users of the rotating logo feature.
42+
validations:
43+
required: false
44+
45+
- type: checkboxes
46+
id: documentation
47+
attributes:
48+
label: Preflight Checklist
49+
options:
50+
- required: true
51+
#language=markdown
52+
label: |
53+
I could not find a solution in the [documentation](https://github.com/jkroepke/openvpn-auth-oauth2/wiki),
54+
the [FAQ](https://github.com/jkroepke/openvpn-auth-oauth2/wiki/FAQ), the existing issues or discussions.
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: ❓ Question
2+
description: Something is not clear.
3+
labels: [❓ question]
4+
body:
5+
- type: textarea
6+
attributes:
7+
label: Problem Statement
8+
description:
9+
Without specifying a solution, describe what the project is missing
10+
today.
11+
placeholder: |
12+
The rotating project logo has a fixed size and color.
13+
There is no way to make it larger and more shiny.
14+
validations:
15+
required: false
16+
17+
- type: textarea
18+
attributes:
19+
label: openvpn-auth-oauth2 logs
20+
description: |
21+
Log of openvpn-auth-oauth2. Output of `journalctl -flu openvpn-auth-oauth2` and `dmesg | grep openvpn`, if openvpn-auth-oauth2 is installed as linux package.
22+
⚠️ Without proving logs, I unable to assist in case of issues. ⚠️
23+
render: shell
24+
validations:
25+
required: true
26+
27+
- type: markdown
28+
attributes:
29+
value:
30+
Please not that openvpn-auth-oauth2 requires an OpenVPN server version
31+
2.6.2 or higher.
32+
33+
- type: textarea
34+
attributes:
35+
label: Environment
36+
description: |
37+
examples:
38+
- **openvpn-auth-oauth2 Version**: 1.5.1
39+
- **OpenVPN Server Version**: 2.6.2
40+
- **Server OS**: Linux
41+
- **OpenVPN Client (flavor, OS)**: Tunnelblick 4.0.0beta10 / MacOD
42+
value: |
43+
- openvpn-auth-oauth2 Version:
44+
- OpenVPN Server Version:
45+
- Server OS:
46+
- OpenVPN Client (flavor, OS):
47+
validations:
48+
required: false
49+
50+
- type: checkboxes
51+
id: documentation
52+
attributes:
53+
label: Preflight Checklist
54+
options:
55+
- required: true
56+
#language=markdown
57+
label: |
58+
I could not find a solution in the [documentation](https://github.com/jkroepke/openvpn-auth-oauth2/wiki),
59+
the [FAQ](https://github.com/jkroepke/openvpn-auth-oauth2/wiki/FAQ), the existing issues or discussions.

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,6 @@ Complete these before marking the PR as `ready to review`:
2020
- [ ] [DCO](https://github.com/prometheus-community/helm-charts/blob/main/CONTRIBUTING.md#sign-off-your-work)
2121
signed
2222
- [ ] The PR title has a summary of the changes
23+
- [ ] The PR title begins with `feat:`, `fix:` or `chore:`
2324
- [ ] The PR body has a summary to reflect any significant (and particularly
2425
user-facing) changes introduced by this PR

.github/labeler.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
version: 1
2+
appendOnly: true
3+
labels:
4+
- label: 'chore'
5+
type: 'pull_request'
6+
title: '^chore:.*'
7+
- label: '🐞 bug'
8+
type: 'pull_request'
9+
title: '^fix:.*'
10+
- label: '✨ enhancement'
11+
type: 'pull_request'
12+
title: '^feat:.*'
13+
- label: '📖 docs'
14+
type: 'pull_request'
15+
title: '^docs:.*'

.github/workflows/ci.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,10 @@ jobs:
6868
VALIDATE_ALL_CODEBASE: true
6969
VALIDATE_BASH: true
7070
VALIDATE_BASH_EXEC: true
71-
VALIDATE_EDITORCONFIG: true
7271
VALIDATE_ENV: true
7372
VALIDATE_GITHUB_ACTIONS: true
7473
VALIDATE_HTML: true
75-
# VALIDATE_JSON: true
7674
VALIDATE_NATURAL_LANGUAGE: true
77-
# VALIDATE_RENOVATE: true
7875
VALIDATE_SHELL_SHFMT: true
7976
VALIDATE_XML: true
8077
VALIDATE_YAML: true

.github/workflows/pr.yaml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: Pull Request
2+
on:
3+
pull_request:
4+
types:
5+
- opened
6+
- reopened
7+
- synchronize
8+
- labeled
9+
- unlabeled
10+
11+
permissions: {}
12+
13+
jobs:
14+
add-labels:
15+
runs-on: ubuntu-latest
16+
if: >-
17+
!contains(github.event.pull_request.labels.*.name, '💥 breaking-change') &&
18+
!contains(github.event.pull_request.labels.*.name, '✨ enhancement') &&
19+
!contains(github.event.pull_request.labels.*.name, '🐞 bug') &&
20+
!contains(github.event.pull_request.labels.*.name, '📖 docs') &&
21+
!contains(github.event.pull_request.labels.*.name, 'chore') &&
22+
!contains(github.event.pull_request.labels.*.name, '🛠️ dependencies')
23+
steps:
24+
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
25+
id: app-token
26+
with:
27+
app-id: 1248576
28+
private-key: ${{ secrets.APP_RENOVATE_HELPER_PRIVATE_KEY }}
29+
- uses: srvaroa/labeler@v1
30+
env:
31+
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
32+
validate-labels:
33+
name: check labels missing
34+
runs-on: ubuntu-latest
35+
steps:
36+
- name: check
37+
if: >-
38+
!contains(github.event.pull_request.labels.*.name, '💥 breaking-change') &&
39+
!contains(github.event.pull_request.labels.*.name, '✨ enhancement') &&
40+
!contains(github.event.pull_request.labels.*.name, '🐞 bug') &&
41+
!contains(github.event.pull_request.labels.*.name, '📖 docs') &&
42+
!contains(github.event.pull_request.labels.*.name, 'chore') &&
43+
!contains(github.event.pull_request.labels.*.name, '🛠️ dependencies')
44+
run: >-
45+
echo One of the following labels is missing on this PR:
46+
breaking-change enhancement bug docs chore && exit 1
47+
validate-title:
48+
name: check title prefix
49+
runs-on: ubuntu-latest
50+
steps:
51+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
52+
- name: check
53+
run: |
54+
PR_TITLE_PREFIX=$(echo "$PR_TITLE" | cut -d':' -f1)
55+
if [[ "$PR_TITLE_PREFIX" == "fix"* ]] || [[ "$PR_TITLE_PREFIX" == "feat"* ]] || [[ "$PR_TITLE_PREFIX" == "chore"* ]]; then
56+
exit 0
57+
fi
58+
59+
echo "PR title must start with feat, fix or chore"
60+
exit 1
61+
env:
62+
PR_TITLE: ${{ github.event.pull_request.title }}

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.github/**/*.yaml

0 commit comments

Comments
 (0)