-
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
Jozef Volak
committed
Aug 6, 2024
1 parent
de6b849
commit 051c98b
Showing
59 changed files
with
4,241 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,7 @@ | ||
remote: origin | ||
target-branch: main | ||
check-version-increment: false | ||
chart-dirs: | ||
- apps/dev | ||
- apps/stage | ||
- apps/prod |
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 @@ | ||
name: Codespell | ||
|
||
on: pull_request | ||
|
||
jobs: | ||
codespell: | ||
name: Codespell | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
- name: Codespell | ||
uses: codespell-project/actions-codespell@master | ||
with: | ||
ignore_words_list: aks | ||
check_filenames: true | ||
check_hidden: false | ||
skip: ./.git,*-secret.yaml,codespell.yaml |
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,116 @@ | ||
name: Kustomized-Helm manifest diff | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
list-changed-charts: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
outputs: | ||
changed_charts: ${{ steps.list-changed.outputs.charts }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: azure/setup-helm@v3 | ||
with: | ||
version: v3.12.1 | ||
|
||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
check-latest: true | ||
|
||
- uses: helm/[email protected] | ||
|
||
- name: Run chart-testing (list-changed) | ||
id: list-changed | ||
run: | | ||
changed_files=$(ct list-changed --config .github/lint_config.yaml | jq -R -s -c 'split("\n") | map(select(. != ""))') | ||
echo "Changed files: $changed_files" | ||
echo "charts=${changed_files}" >> "$GITHUB_OUTPUT" | ||
dynamic_matrix: | ||
needs: list-changed-charts | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
strategy: | ||
matrix: | ||
file: ${{ fromJson(needs.list-changed-charts.outputs.changed_charts) }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
path: head | ||
|
||
- uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.pull_request.base.ref }} | ||
fetch-depth: 0 | ||
path: main | ||
|
||
- uses: azure/setup-helm@v3 | ||
with: | ||
version: v3.12.1 | ||
|
||
- name: Helm dependency update and render | ||
run: | | ||
REF_PATH=head | ||
if [ ! -d "${REF_PATH}/${{ matrix.file }}" ]; then | ||
mkdir -p "${REF_PATH}/${{ matrix.file }}" | ||
touch "${REF_PATH}/${{ matrix.file }}/all.yaml" | ||
touch "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo "apiVersion: kustomize.config.k8s.io/v1beta1" > "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo "kind: Kustomization" >> "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo "resources:" >> "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo " - all.yaml" >> "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
else | ||
pushd ${REF_PATH}/${{ matrix.file }} | ||
helm dependency update | ||
helm template . --name-template $(basename $PWD) --namespace frinx --values values.yaml --values cluster-values.yaml --include-crds > all.yaml | ||
popd | ||
fi | ||
- name: Helm dependency update and render | ||
run: | | ||
REF_PATH=main | ||
if [ ! -d "${REF_PATH}/${{ matrix.file }}" ]; then | ||
mkdir -p "${REF_PATH}/${{ matrix.file }}" | ||
touch "${REF_PATH}/${{ matrix.file }}/all.yaml" | ||
touch "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo "apiVersion: kustomize.config.k8s.io/v1beta1" > "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo "kind: Kustomization" >> "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo "resources:" >> "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
echo " - all.yaml" >> "${REF_PATH}/${{ matrix.file }}/kustomization.yaml" | ||
else | ||
pushd ${REF_PATH}/${{ matrix.file }} | ||
helm dependency update | ||
helm template . --name-template $(basename $PWD) --namespace frinx --values values.yaml --values cluster-values.yaml --include-crds > all.yaml | ||
popd | ||
fi | ||
- uses: int128/kustomize-action@v1 | ||
id: kustomize-head | ||
with: | ||
base-directory: head/${{ matrix.file }} | ||
kustomization: kustomization.yaml | ||
write-individual-files: true | ||
|
||
- uses: int128/kustomize-action@v1 | ||
id: kustomize-base | ||
with: | ||
base-directory: main/${{ matrix.file }} | ||
kustomization: kustomization.yaml | ||
write-individual-files: true | ||
|
||
- uses: int128/diff-action@v1 | ||
with: | ||
base: ${{ steps.kustomize-base.outputs.directory }} | ||
head: ${{ steps.kustomize-head.outputs.directory }} |
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,22 @@ | ||
name: Kustomized-Helm manifest diff | ||
|
||
on: | ||
pull_request: | ||
|
||
env: | ||
KUBE_SCORE_VERSION: 1.18.0 | ||
|
||
jobs: | ||
|
||
kube-score: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: install kube-scre | ||
run: | | ||
wget https://github.com/zegl/kube-score/releases/download/v${{ env.KUBE_SCORE_VERSION}}/kube-score_${{ env.KUBE_SCORE_VERSION}}_linux_amd64 -O /usr/local/bin/kube-score | ||
chmod +x /usr/local/bin/kube-score | ||
- run: kube-score version |
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 @@ | ||
*.tgz | ||
*.lock | ||
**/temp/* | ||
.idea |
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,66 @@ | ||
apiVersion: argoproj.io/v1alpha1 | ||
kind: ApplicationSet | ||
metadata: | ||
name: frinx-machine-persistence-dev | ||
namespace: argocd | ||
# finalizers: | ||
# - resources-finalizer.argocd.argoproj.io | ||
labels: | ||
deployment: fm-dev | ||
type: frinx-machine-persistence | ||
spec: | ||
goTemplate: true | ||
goTemplateOptions: ["missingkey=error"] | ||
generators: | ||
# - matrix: | ||
# generators: | ||
# - list: | ||
# elements: | ||
# - cluster: in-cluster | ||
# namespace: fm-dev | ||
# project: default | ||
- list: | ||
elements: | ||
- name: frinx-arango-config | ||
- name: kafka | ||
- name: postgresql | ||
- name: timescale-db | ||
- name: uniconfig-postgres | ||
template: | ||
metadata: | ||
name: "{{name}}-dev" | ||
labels: | ||
name: "{{name}}" | ||
type: frinx-machine-persistence | ||
finalizers: | ||
- resources-finalizer.argocd.argoproj.io | ||
spec: | ||
project: "default" | ||
destination: | ||
name: "in-cluster" | ||
namespace: "fm-dev" | ||
|
||
syncPolicy: | ||
automated: | ||
prune: true | ||
selfHeal: true | ||
syncOptions: | ||
- CreateNamespace=true | ||
- ServerSideApply=true | ||
retry: | ||
limit: 5 | ||
backoff: | ||
duration: 5s | ||
factor: 2 | ||
maxDuration: 3m | ||
|
||
source: | ||
repoURL: [email protected]:FRINXio/gitops-boilerplate.git | ||
targetRevision: HEAD | ||
path: "apps/dev/frinx-machine-persistence/{{name}}" | ||
plugin: | ||
name: kustomized-helm | ||
parameters: | ||
- name: helm-template-extra-args | ||
string: | | ||
-f values.yaml -f cluster-values.yaml |
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,24 @@ | ||
# Patterns to ignore when building packages. | ||
# This supports shell glob matching, relative path matching, and | ||
# negation (prefixed with !). Only one pattern per line. | ||
.DS_Store | ||
# Common VCS dirs | ||
.git/ | ||
.gitignore | ||
.bzr/ | ||
.bzrignore | ||
.hg/ | ||
.hgignore | ||
.svn/ | ||
# Common backup files | ||
*.swp | ||
*.bak | ||
*.tmp | ||
*.orig | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj | ||
.vscode/ | ||
|
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,13 @@ | ||
apiVersion: v2 | ||
name: frinx-machine-monitoring | ||
description: Kubernetes deployment of FRINX-machine | ||
icon: https://avatars.githubusercontent.com/u/23452093?s=200&v=4 | ||
type: application | ||
version: 6.1.0 | ||
maintainers: | ||
- name: FRINX | ||
dependencies: | ||
- name: frinx-machine | ||
# repository: https://FRINXio.github.io/helm-charts | ||
repository: file:///home/jozef/Documents/frinx/github/FM-debug/helm-charts/charts/frinx-machine | ||
version: 9.0.0 |
Empty file.
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,5 @@ | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
|
||
resources: | ||
- all.yaml |
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,11 @@ | ||
frinx-machine: | ||
frinx-machine-monitoring: | ||
grafana: | ||
ingress: | ||
enabled: true | ||
ingressClassName: nginx | ||
# Values can be templated | ||
path: / | ||
pathType: Prefix | ||
hosts: | ||
- grafana.127.0.0.1.nip.io |
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,12 @@ | ||
frinx-machine: | ||
frinx-machine-monitoring: | ||
enabled: true | ||
|
||
frinx-machine-operators: | ||
enabled: false | ||
|
||
frinx-machine-core: | ||
enabled: false | ||
|
||
frinx-machine-persistence: | ||
enabled: false |
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,24 @@ | ||
# Patterns to ignore when building packages. | ||
# This supports shell glob matching, relative path matching, and | ||
# negation (prefixed with !). Only one pattern per line. | ||
.DS_Store | ||
# Common VCS dirs | ||
.git/ | ||
.gitignore | ||
.bzr/ | ||
.bzrignore | ||
.hg/ | ||
.hgignore | ||
.svn/ | ||
# Common backup files | ||
*.swp | ||
*.bak | ||
*.tmp | ||
*.orig | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj | ||
.vscode/ | ||
|
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 @@ | ||
apiVersion: v2 | ||
name: frinx-machine-operators | ||
description: Kubernetes deployment of FRINX-machine | ||
icon: https://avatars.githubusercontent.com/u/23452093?s=200&v=4 | ||
type: application | ||
version: 6.1.0 | ||
maintainers: | ||
- name: FRINX | ||
dependencies: | ||
- name: frinx-machine | ||
# repository: https://FRINXio.github.io/helm-charts | ||
repository: file:///home/jozef/Documents/frinx/github/FM-debug/helm-charts/charts/frinx-machine | ||
version: 9.0.0 | ||
|
Empty file.
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,5 @@ | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
|
||
resources: | ||
- all.yaml |
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,13 @@ | ||
frinx-machine: | ||
|
||
frinx-machine-operators: | ||
enabled: true | ||
|
||
frinx-machine-monitoring: | ||
enabled: false | ||
|
||
frinx-machine-core: | ||
enabled: false | ||
|
||
frinx-machine-persistence: | ||
enabled: false |
24 changes: 24 additions & 0 deletions
24
apps/dev/frinx-machine-persistence/frinx-arango-config/.helmignore
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,24 @@ | ||
# Patterns to ignore when building packages. | ||
# This supports shell glob matching, relative path matching, and | ||
# negation (prefixed with !). Only one pattern per line. | ||
.DS_Store | ||
# Common VCS dirs | ||
.git/ | ||
.gitignore | ||
.bzr/ | ||
.bzrignore | ||
.hg/ | ||
.hgignore | ||
.svn/ | ||
# Common backup files | ||
*.swp | ||
*.bak | ||
*.tmp | ||
*.orig | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj | ||
.vscode/ | ||
|
Oops, something went wrong.