generated from onedr0p/cluster-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 283ae23
Showing
150 changed files
with
4,345 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# editorconfig.org | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.{bash,py,sh}] | ||
indent_style = space | ||
indent_size = 4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
* text=auto eol=lf | ||
*.yaml.j2 linguist-language=YAML | ||
*.sops.* diff=sopsdiffer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
area/templates: | ||
- changed-files: | ||
- any-glob-to-any-file: templates/**/* | ||
area/github: | ||
- changed-files: | ||
- any-glob-to-any-file: .github/**/* | ||
area/kubernetes: | ||
- changed-files: | ||
- any-glob-to-any-file: kubernetes/**/* | ||
area/taskfile: | ||
- changed-files: | ||
- any-glob-to-any-file: .taskfiles/**/* | ||
- any-glob-to-any-file: Taskfile* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
# Area | ||
- { name: "area/templates", color: "0e8a16" } | ||
- { name: "area/github", color: "0e8a16" } | ||
- { name: "area/kubernetes", color: "0e8a16" } | ||
- { name: "area/taskfile", color: "0e8a16" } | ||
# Renovate | ||
- { name: "renovate/container", color: "027fa0" } | ||
- { name: "renovate/github-action", color: "027fa0" } | ||
- { name: "renovate/github-release", color: "027fa0" } | ||
- { name: "renovate/helm", color: "027fa0" } | ||
# Semantic Type | ||
- { name: "type/patch", color: "ffec19" } | ||
- { name: "type/minor", color: "ff9800" } | ||
- { name: "type/major", color: "f6412d" } | ||
- { name: "type/break", color: "f6412d" } | ||
# Uncategorized | ||
- { name: "hold", color: "ee0701" } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
changelog: | ||
exclude: | ||
authors: | ||
- renovate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,205 @@ | ||
{ | ||
"$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
"extends": [ | ||
"config:recommended", | ||
"docker:enableMajor", | ||
":automergeBranch", | ||
":dependencyDashboard", | ||
":disableRateLimiting", | ||
":semanticCommits", | ||
":separatePatchReleases" | ||
], | ||
"dependencyDashboard": true, | ||
"dependencyDashboardTitle": "Renovate Dashboard 🤖", | ||
"suppressNotifications": ["prEditedNotification", "prIgnoreNotification"], | ||
"schedule": ["every weekend"], | ||
"ignorePaths": ["**/*.sops.*"], | ||
"flux": { | ||
"fileMatch": ["(^|/)kubernetes/.+\\.ya?ml(?:\\.j2)?$"] | ||
}, | ||
"helm-values": { | ||
"fileMatch": ["(^|/)kubernetes/.+\\.ya?ml(?:\\.j2)?$"] | ||
}, | ||
"helmfile": { | ||
"fileMatch": ["(^|/)helmfile\\.ya?ml(?:\\.j2)?$"] | ||
}, | ||
"kubernetes": { | ||
"fileMatch": ["(^|/)kubernetes/.+\\.ya?ml(?:\\.j2)?$"] | ||
}, | ||
"kustomize": { | ||
"fileMatch": ["(^|/)kustomization\\.ya?ml(?:\\.j2)?$"] | ||
}, | ||
"pip_requirements": { | ||
"fileMatch": ["(^|/)[\\w-]*requirements(-\\w+)?\\.(txt|pip)(?:\\.j2)?$"] | ||
}, | ||
"packageRules": [ | ||
{ | ||
"description": ["Auto-merge GitHub Actions for minor and patch"], | ||
"matchManagers": ["github-actions"], | ||
"automerge": true, | ||
"automergeType": "branch", | ||
"ignoreTests": true, | ||
"matchUpdateTypes": ["minor", "patch"] | ||
}, | ||
{ | ||
"description": ["Flux Operator Group"], | ||
"groupName": "Flux Operator", | ||
"matchPackagePatterns": ["flux-operator", "flux-instance"], | ||
"matchDatasources": ["docker"], | ||
"group": { | ||
"commitMessageTopic": "{{{groupName}}} group" | ||
} | ||
}, | ||
{ | ||
"description": ["Talos Group"], | ||
"groupName": "Talos", | ||
"matchPackagePatterns": [ | ||
"siderolabs/talosctl", | ||
"siderolabs/installer" | ||
], | ||
"matchDatasources": ["docker"], | ||
"group": { | ||
"commitMessageTopic": "{{{groupName}}} group" | ||
} | ||
}, | ||
{ | ||
"matchDatasources": ["docker"], | ||
"matchUpdateTypes": ["major"], | ||
"commitMessagePrefix": "feat(container)!: ", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": " ( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["docker"], | ||
"matchUpdateTypes": ["minor"], | ||
"semanticCommitType": "feat", | ||
"semanticCommitScope": "container", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["docker"], | ||
"matchUpdateTypes": ["patch"], | ||
"semanticCommitType": "fix", | ||
"semanticCommitScope": "container", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["docker"], | ||
"matchUpdateTypes": ["digest"], | ||
"semanticCommitType": "chore", | ||
"semanticCommitScope": "container", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentDigestShort}} → {{newDigestShort}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["helm"], | ||
"matchUpdateTypes": ["major"], | ||
"commitMessagePrefix": "feat(helm)!: ", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["helm"], | ||
"matchUpdateTypes": ["minor"], | ||
"semanticCommitType": "feat", | ||
"semanticCommitScope": "helm", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["helm"], | ||
"matchUpdateTypes": ["patch"], | ||
"semanticCommitType": "fix", | ||
"semanticCommitScope": "helm", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["github-releases", "github-tags"], | ||
"matchUpdateTypes": ["major"], | ||
"commitMessagePrefix": "feat(github-release)!: ", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["github-releases", "github-tags"], | ||
"matchUpdateTypes": ["minor"], | ||
"semanticCommitType": "feat", | ||
"semanticCommitScope": "github-release", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchDatasources": ["github-releases", "github-tags"], | ||
"matchUpdateTypes": ["patch"], | ||
"semanticCommitType": "fix", | ||
"semanticCommitScope": "github-release", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchManagers": ["github-actions"], | ||
"matchUpdateTypes": ["major"], | ||
"commitMessagePrefix": "feat(github-action)!: ", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchManagers": ["github-actions"], | ||
"matchUpdateTypes": ["minor"], | ||
"semanticCommitType": "feat", | ||
"semanticCommitScope": "github-action", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchManagers": ["github-actions"], | ||
"matchUpdateTypes": ["patch"], | ||
"semanticCommitType": "fix", | ||
"semanticCommitScope": "github-action", | ||
"commitMessageTopic": "{{depName}}", | ||
"commitMessageExtra": "( {{currentVersion}} → {{newVersion}} )" | ||
}, | ||
{ | ||
"matchUpdateTypes": ["major"], | ||
"labels": ["type/major"] | ||
}, | ||
{ | ||
"matchUpdateTypes": ["minor"], | ||
"labels": ["type/minor"] | ||
}, | ||
{ | ||
"matchUpdateTypes": ["patch"], | ||
"labels": ["type/patch"] | ||
}, | ||
{ | ||
"matchDatasources": ["docker"], | ||
"addLabels": ["renovate/container"] | ||
}, | ||
{ | ||
"matchDatasources": ["helm"], | ||
"addLabels": ["renovate/helm"] | ||
}, | ||
{ | ||
"matchDatasources": ["github-releases", "github-tags"], | ||
"addLabels": ["renovate/github-release"] | ||
}, | ||
{ | ||
"matchManagers": ["github-actions"], | ||
"addLabels": ["renovate/github-action"] | ||
} | ||
], | ||
"customManagers": [ | ||
{ | ||
"customType": "regex", | ||
"description": ["Process YAML custom dependencies"], | ||
"fileMatch": ["(^|/)kubernetes/.+\\.ya?ml(?:\\.j2)?$"], | ||
"matchStrings": [ | ||
"datasource=(?<datasource>\\S+) depName=(?<depName>\\S+)( repository=(?<registryUrl>\\S+))?\\n.+(:\\s|=)(&\\S+\\s)?(?<currentValue>\\S+)", | ||
], | ||
"datasourceTemplate": "{{#if datasource}}{{{datasource}}}{{else}}github-releases{{/if}}" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
skip_tests: true | ||
|
||
node_network: 10.10.10.0/24 | ||
node_default_gateway: 10.10.10.1 | ||
node_inventory: | ||
- name: k8s-controller-0 | ||
address: 10.10.10.100 | ||
controller: true | ||
disk: fake | ||
mac_addr: fake | ||
schematic_id: "376567988ad370138ad8b2698212367b8edcb69b5fd68c80be1f2ec7d603b4ba" | ||
secureboot: true | ||
encrypt_disk: true | ||
- name: k8s-worker-0 | ||
address: 10.10.10.101 | ||
controller: false | ||
disk: fake | ||
mac_addr: fake | ||
schematic_id: "376567988ad370138ad8b2698212367b8edcb69b5fd68c80be1f2ec7d603b4ba" | ||
secureboot: false | ||
encrypt_disk: false | ||
dns_servers: ["1.1.1.1", "1.0.0.1"] | ||
ntp_servers: ["time.cloudflare.com"] | ||
pod_network: 10.69.0.0/16 | ||
service_network: 10.96.0.0/16 | ||
controller_vip: 10.10.10.254 | ||
tls_sans: ["fake"] | ||
age_pubkey: $TEMPLATE_AGE_PUBLIC_KEY | ||
bgp: | ||
enabled: false | ||
github: | ||
address: https://github.com/onedr0p/cluster-template | ||
branch: main | ||
webhook_token: fake | ||
cloudflare: | ||
enabled: true | ||
domain: fake | ||
token: take | ||
acme: | ||
email: [email protected] | ||
production: false | ||
tunnel: | ||
account_id: fake | ||
id: fake | ||
secret: fake | ||
ingress_vip: 10.10.10.252 | ||
ingress_vip: 10.10.10.251 | ||
gateway_vip: 10.10.10.253 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
--- | ||
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | ||
name: "e2e" | ||
|
||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: ["main"] | ||
paths-ignore: | ||
- kubernetes/** | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.number || github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
configure: | ||
if: ${{ github.repository == 'onedr0p/cluster-template' }} | ||
name: configure | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
config-files: | ||
- talos | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup mise | ||
uses: jdx/mise-action@v2 | ||
env: | ||
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | ||
|
||
- name: Install dependencies | ||
run: mise run deps | ||
|
||
- name: Run age task | ||
run: task template:generate-age-key | ||
|
||
- name: Run init task | ||
run: | | ||
task init | ||
cp ./.github/tests/config-${{ matrix.config-files }}.yaml ./config.yaml | ||
export TEMPLATE_AGE_PUBLIC_KEY=$(sed -n 's/# public key: //gp' age.key) | ||
envsubst < ./config.yaml > ./config.yaml.tmp && mv ./config.yaml.tmp ./config.yaml | ||
- name: Run configure task | ||
run: task configure --yes | ||
|
||
- name: Run generate talconfig task | ||
run: task talos:generate-config | ||
|
||
- name: Run flux-local test | ||
uses: docker://ghcr.io/allenporter/flux-local:v7.0.0@sha256:abf237e31d20de26f8a4b08e588cc927cb0a9f0ecf90d04bada00f393b919354 | ||
with: | ||
args: test --enable-helm --all-namespaces --path /github/workspace/kubernetes/flux/cluster -v | ||
|
||
- name: Run cleanup task | ||
run: task template:tidy --yes |
Oops, something went wrong.