Skip to content

Commit

Permalink
Merge pull request #3 from luissimas/feature/flux-ui
Browse files Browse the repository at this point in the history
ci: separate workflows
  • Loading branch information
luissimas authored Apr 9, 2024
2 parents 1d29902 + 8b0644d commit 24d1b97
Show file tree
Hide file tree
Showing 8 changed files with 76 additions and 22 deletions.
22 changes: 3 additions & 19 deletions .github/workflows/k8s.yaml → .github/workflows/e2e.yaml
Original file line number Diff line number Diff line change
@@ -1,29 +1,13 @@
name: k8s
name: e2e

on:
push:
branches: ["main"]
workflow_dispatch:
pull_request:
branches: ["main"]

jobs:
validate-manifests:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup yq
uses: fluxcd/pkg/actions/yq@main
- name: Setup kubeconform
uses: fluxcd/pkg/actions/kubeconform@main
- name: Setup kustomize
uses: fluxcd/pkg/actions/kustomize@main
- name: Validate manifests
run: ./scripts/validate.sh

test-cluster-bootstrap:
cluster-bootstrap:
runs-on: ubuntu-latest
needs: validate-manifests
steps:
- name: Checkout
uses: actions/checkout@v3
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: test

on:
workflow_dispatch:
pull_request:
push:
branches: ["main"]

jobs:
validate-manifests:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup yq
uses: fluxcd/pkg/actions/yq@main
- name: Setup kubeconform
uses: fluxcd/pkg/actions/kubeconform@main
- name: Setup kustomize
uses: fluxcd/pkg/actions/kustomize@main
- name: Validate manifests
run: ./scripts/validate.sh
5 changes: 3 additions & 2 deletions README.org
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ My Homelab setup running as a [[https://k3s.io/][K3S]] cluster.
- [X] GitOps setup with Flux
- [X] Secrets management
- [X] Manifests validation in CI
- [ ] Ensure bootstrap order is correct
- [X] Ensure bootstrap order is correct
- [X] SSL certificates
- [ ] Flux UI
- [ ] SSL certificates
- [ ] Traefik ingress
- [ ] Storage
- [ ] Monitoring stack
1 change: 1 addition & 0 deletions infrastructure/controllers/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ kind: Kustomization
resources:
- cert-manager
- sealed-secrets
- weave-dashboard
5 changes: 5 additions & 0 deletions infrastructure/controllers/weave-dashboard/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- repository.yaml
- release.yaml
22 changes: 22 additions & 0 deletions infrastructure/controllers/weave-dashboard/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
annotations:
metadata.weave.works/description:
This is the Weave GitOps Dashboard. It provides
a simple way to get insights into your GitOps workloads.
name: weave-dashboard
namespace: flux-system
spec:
chart:
spec:
chart: weave-gitops
sourceRef:
kind: HelmRepository
name: weave-dashboard
interval: 1h0m0s
values:
adminUser:
create: true
passwordHash: $2a$10$JA02v0.HgwaJHwvimZii7OJ2rdBRTmeaMOtZ7Mq7TsOXoLY.JST9S
username: admin
18 changes: 18 additions & 0 deletions infrastructure/controllers/weave-dashboard/repository.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
apiVersion: source.toolkit.fluxcd.io/v1beta2
kind: HelmRepository
metadata:
annotations:
metadata.weave.works/description:
This is the source location for the Weave GitOps
Dashboard's helm chart.
labels:
app.kubernetes.io/component: ui
app.kubernetes.io/created-by: weave-gitops-cli
app.kubernetes.io/name: weave-gitops-dashboard
app.kubernetes.io/part-of: weave-gitops
name: weave-dashboard
namespace: flux-system
spec:
interval: 1h0m0s
type: oci
url: oci://ghcr.io/weaveworks/charts
3 changes: 2 additions & 1 deletion shell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
with pkgs;

mkShell {
buildInputs = [ yq-go kustomize kubeconform kubectl kubeseal fluxcd ];
buildInputs =
[ yq-go kustomize kubeconform kubectl kubeseal fluxcd weave-gitops ];
}

0 comments on commit 24d1b97

Please sign in to comment.