Skip to content

Commit 49a50c8

Browse files
author
kranurag7
committed
bootstrap csctl-plugin-openstack repo
this contains boilerplates for working with this repository. Signed-off-by: kranurag7 <[email protected]>
1 parent d4665d5 commit 49a50c8

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+2571
-0
lines changed

.boilerplate.json

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"dirs_to_skip" : [
3+
"hack/boilerplate/testdata/",
4+
"hack/tools/",
5+
"vendor",
6+
".cache",
7+
".pkg"
8+
],
9+
"not_generated_files_to_skip" : [
10+
"hack/boilerplate/boilerplate.py"
11+
]
12+
}

.builder-image-version.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
0.1.0

.github/ISSUE_TEMPLATE/bug_report.md

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
name: 'Bug report'
3+
about: Tell us about a problem you are experiencing.
4+
5+
---
6+
7+
/kind bug
8+
9+
**What steps did you take and what happened:**
10+
[A clear and concise description of what the bug is.]
11+
12+
13+
**What did you expect to happen:**
14+
15+
16+
**Anything else you would like to add:**
17+
[Miscellaneous information that will assist in solving the issue.]
18+
19+
20+
**Environment:**
21+
22+
- csctl-plugin-openstack version: (use `csctl-plugin-openstack version`)
23+
- OS (e.g. from `/etc/os-release`):
+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
name: 'Feature request'
3+
about: Suggest an idea for this project.
4+
5+
---
6+
7+
/kind feature
8+
9+
**Describe the solution you'd like**
10+
[A clear and concise description of what you want to happen.]
11+
12+
13+
**Anything else you would like to add:**
14+
[Miscellaneous information that will assist in solving the issue.]
15+
16+
17+
**Environment:**
18+
19+
- csctl-plugin-openstack version: (use `csctl-plugin-openstack version`)

.github/ISSUE_TEMPLATE/proposal.md

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
name: Enhancement Proposal
3+
about: Propose larger efforts, breaking changes, or new features
4+
5+
---
6+
7+
***Goals***
8+
1. Goal 1
9+
2. Goal 2
10+
11+
***Non-Goals/Future Work***
12+
1. Non-Goal 1
13+
1. Non-Goal 2
14+
15+
**User Story**
16+
17+
As a [developer/user/operator] I would like to [high level description] for [reasons]
18+
19+
**Detailed Description**
20+
21+
[A clear and concise description of what you want to happen.]
22+
23+
/kind proposal

.github/actions/setup-go/action.yaml

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: "Setup Go"
2+
description: "Setup Go"
3+
runs:
4+
using: "composite"
5+
steps:
6+
- name: Install go
7+
uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
8+
with:
9+
go-version-file: "go.mod"
10+
cache: true
11+
cache-dependency-path: go.sum
12+
- id: go-cache-paths
13+
shell: bash
14+
run: |
15+
echo "go-build=$(go env GOCACHE)" >> $GITHUB_OUTPUT
16+
echo "go-mod=$(go env GOMODCACHE)" >> $GITHUB_OUTPUT
17+
- name: Go Mod Cache
18+
uses: actions/cache@ab5e6d0c87105b4c9c2047343972218f562e4319 # v4
19+
with:
20+
path: ${{ steps.go-cache-paths.outputs.go-mod }}
21+
key: ${{ runner.os }}-go-mod-${{ hashFiles('**/go.sum') }}
22+
restore-keys: |
23+
${{ runner.os }}-go-mod-
24+
- name: Go Build Cache
25+
uses: actions/cache@ab5e6d0c87105b4c9c2047343972218f562e4319 # v4
26+
with:
27+
path: ${{ steps.go-cache-paths.outputs.go-build }}
28+
key: ${{ runner.os }}-go-build-${{ hashFiles('**/go.sum') }}
29+
restore-keys: |
30+
${{ runner.os }}-go-build-

.github/labeler.yaml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
area/code:
3+
- changed-files:
4+
- any-glob-to-any-file: "controllers/**/*"
5+
- any-glob-to-any-file: "pkg/**/*"
6+
area/api:
7+
- changed-files:
8+
- any-glob-to-any-file: "api/**/*"
9+
- any-glob-to-any-file: "config/crd/**/*"
10+
area/github:
11+
- changed-files:
12+
- any-glob-to-any-file: ".github/**/*"
13+
area/hack:
14+
- changed-files:
15+
- any-glob-to-any-file: "hack/**/*"
16+
- any-glob-to-any-file: "Makefile"
17+
area/test:
18+
- changed-files:
19+
- any-glob-to-any-file: "test/**/*"
20+
area/templates:
21+
- changed-files:
22+
- any-glob-to-any-file: "templates/**/*"

.github/labels.yaml

+80
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
---
2+
# Area
3+
- name: area/code
4+
color: "72ccf3"
5+
description: >-
6+
Changes made in the code directory
7+
- name: area/api
8+
color: "72ccf3"
9+
description: >-
10+
Changes made in the api directory
11+
- name: area/github
12+
color: "72ccf3"
13+
description: >-
14+
Changes made in the github directory
15+
- name: area/hack
16+
color: "72ccf3"
17+
description: >-
18+
Changes made in the hack directory
19+
- name: area/test
20+
color: "72ccf3"
21+
description: >-
22+
Changes made in the test directory
23+
- name: area/templates
24+
color: "72ccf3"
25+
description: >-
26+
Changes made in the templates directory
27+
# Update
28+
- name: update/container
29+
color: "ffc300"
30+
- name: update/github-action
31+
color: "ffc300"
32+
- name: update/helm
33+
color: "ffc300"
34+
- name: update/go
35+
color: "ffc300"
36+
# Semantic Type
37+
- name: type/patch
38+
color: "FFEC19"
39+
- name: type/minor
40+
color: "FF9800"
41+
- name: type/major
42+
color: "F6412D"
43+
# Size
44+
- name: size/XS
45+
color: "009900"
46+
description: >-
47+
Denotes a PR that changes 0-20 lines, ignoring generated files.
48+
- name: size/S
49+
color: "77bb00"
50+
description: >-
51+
Denotes a PR that changes 20-50 lines, ignoring generated files.
52+
- name: size/M
53+
color: "eebb00"
54+
description: >-
55+
Denotes a PR that changes 50-200 lines, ignoring generated files.
56+
- name: size/L
57+
color: "ee9900"
58+
description: >-
59+
Denotes a PR that changes 200-800 lines, ignoring generated files.
60+
- name: size/XL
61+
color: "ee5500"
62+
description: >-
63+
Denotes a PR that changes 800-2000 lines, ignoring generated files.
64+
- name: size/XXL
65+
color: "ee0000"
66+
description: >-
67+
Denotes a PR that changes 2000+ lines, ignoring generated files.
68+
# Uncategorized
69+
- name: bug
70+
color: "ee0701"
71+
- name: do-not-merge
72+
color: "ee0701"
73+
- name: docs
74+
color: "F4D1B7"
75+
- name: enhancement
76+
color: "84b6eb"
77+
- name: link-checker
78+
color: "7B55D7"
79+
- name: question
80+
color: "cc317c"

.github/pull_request_template.md

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<!-- If this is your first PR, welcome! Please make sure you read the [contributing guidelines](../CONTRIBUTING.md#contributing-a-patch). -->
2+
<!-- please add an icon to the title of this PR and delete this line and similar ones -->
3+
<!-- the icon will be either ⚠️ (:warning:, major or breaking changes), ✨ (:sparkles:, feature additions), 🐛 (:bug:, patches and bugfixes), 📖 (:book:, documentation or proposals), or 🌱 (:seedling:, minor or other) -->
4+
5+
**What this PR does / why we need it**:
6+
7+
**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
8+
Fixes #
9+
10+
**Special notes for your reviewer**:
11+
12+
_Please confirm that if this PR changes any image versions, then that's the sole change this PR makes._
13+
14+
**TODOs**:
15+
16+
- [ ] squash commits
17+
- [ ] include documentation
18+
- [ ] add unit tests
19+

.github/renovate.json5

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
{
2+
extends: [
3+
":dependencyDashboard",
4+
":semanticPrefixFixDepsChoreOthers",
5+
":autodetectRangeStrategy",
6+
":disableRateLimiting",
7+
":semanticCommits",
8+
"helpers:pinGitHubActionDigests",
9+
"github>whitesource/merge-confidence:beta",
10+
"github>SovereignCloudStack/csctl-plugin-openstack//.github/renovate/commitMessage.json5",
11+
"github>SovereignCloudStack/csctl-plugin-openstack//.github/renovate/approval.json5",
12+
"github>SovereignCloudStack/csctl-plugin-openstack//.github/renovate/golang.json5",
13+
"github>SovereignCloudStack/csctl-plugin-openstack//.github/renovate/groups.json5",
14+
"github>SovereignCloudStack/csctl-plugin-openstack//.github/renovate/labels.json5",
15+
"github>SovereignCloudStack/csctl-plugin-openstack//.github/renovate/regexManagers.json5"
16+
],
17+
platform: "github",
18+
baseBranches: ["main"],
19+
onboarding: false,
20+
requireConfig: "ignored",
21+
timezone: "Europe/Berlin",
22+
// repo config
23+
repositories: ["SovereignCloudStack/csctl-plugin-openstack"],
24+
ignorePaths: [
25+
"**/vendor/**",
26+
"**/test/**",
27+
"**/tests/**"
28+
],
29+
username: "cluster-stack-bot[bot]",
30+
gitAuthor: "cluster-stack-bot[bot] <143188378+cluster-stack-bot[bot]@users.noreply.github.com>",
31+
// PR config
32+
dependencyDashboardTitle: "Dependency Dashboard 🤖",
33+
dependencyDashboardHeader: "",
34+
prFooter: "",
35+
suppressNotifications: ["prIgnoreNotification"],
36+
rebaseWhen: "conflicted",
37+
commitBodyTable: true,
38+
prHourlyLimit: 1,
39+
printConfig: true,
40+
pruneStaleBranches: true,
41+
allowPostUpgradeCommandTemplating: true,
42+
separateMajorMinor: true,
43+
separateMultipleMajor: true,
44+
separateMinorPatch: true,
45+
enabledManagers: ["dockerfile", "gomod", "github-actions", "regex"],
46+
recreateClosed: true,
47+
}

.github/renovate/approval.json5

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
packageRules: [
3+
{
4+
matchUpdateTypes: ["major", "minor"],
5+
matchManagers: ["gomod"],
6+
matchDepTypes: ["golang"],
7+
description: "Ask for approval for golang updates",
8+
dependencyDashboardApproval: true,
9+
},
10+
],
11+
}

.github/renovate/commitMessage.json5

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"commitMessagePrefix": ":seedling: ",
3+
"commitMessageTopic": "{{depName}}",
4+
"commitMessageExtra": "to {{newVersion}}",
5+
"commitMessageSuffix": "",
6+
"group": { commitMessageTopic: "{{{groupName}}} group" },
7+
"packageRules": [
8+
{
9+
"matchDatasources": ["helm"],
10+
"commitMessageTopic": "chart {{depName}}"
11+
},
12+
{
13+
"matchDatasources": ["docker"],
14+
"commitMessageTopic": "image {{depName}}",
15+
"commitMessageExtra": "to {{#if isSingleVersion}}v{{{newVersion}}}{{else}}{{{newValue}}}{{/if}}"
16+
}
17+
]
18+
}

.github/renovate/golang.json5

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
golang: {
3+
postUpdateOptions: ["gomodTidy", "gomodUpdateImportPaths"],
4+
},
5+
// https://docs.renovatebot.com/configuration-options/#constraints
6+
"constraints": {
7+
"go": "1.21"
8+
},
9+
packageRules: [
10+
{
11+
description: "Disable Golang update for major and minor versions",
12+
matchManagers: ["dockerfile"],
13+
matchDepNames: ["docker.io/library/golang"],
14+
matchUpdateTypes: ["major", "minor"],
15+
enabled: false,
16+
},
17+
{
18+
description: "Disable slim-sprig",
19+
matchManagers: ["gomod"],
20+
matchDepNames: ["github.com/go-task/slim-sprig"],
21+
matchPaths: ["hack/tools/**"],
22+
enabled: false,
23+
},
24+
{
25+
description: "Disable update k8s packages",
26+
matchManagers: ["gomod"],
27+
matchDepNames: ["k8s.io/api", "k8s.io/apimachinery", "k8s.io/apiserver", "k8s.io/client-go", "k8s.io/kubectl", "k8s.io/code-generator"],
28+
enabled: false,
29+
},
30+
],
31+
}

0 commit comments

Comments
 (0)