Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move Tekton from Pulumi to Flux #1593

Merged
merged 1 commit into from
Feb 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 42 additions & 3 deletions kubernetes/resources/flux/flux-kustomizations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: provider
name: tekton-operator
namespace: default
spec:
interval: 2m
path: "./kubernetes/resources/provider"
path: "./kubernetes/vendor/tekton-operator"
prune: true
force: true
retryInterval: 20s
Expand All @@ -16,8 +16,25 @@ spec:
kind: GitRepository
name: nativelink
namespace: default
---
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: tekton-config
namespace: default
spec:
interval: 2m
path: "./kubernetes/resources/tekton-config"
prune: true
force: true
retryInterval: 20s
wait: true
sourceRef:
kind: GitRepository
name: nativelink
namespace: default
dependsOn:
- name: nativelink-tekton-resources
- name: tekton-operator
---
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
Expand All @@ -36,3 +53,25 @@ spec:
kind: GitRepository
name: nativelink
namespace: default
dependsOn:
- name: tekton-config
---
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: provider
namespace: default
spec:
interval: 2m
path: "./kubernetes/resources/provider"
prune: true
force: true
retryInterval: 20s
targetNamespace: default
wait: true
sourceRef:
kind: GitRepository
name: nativelink
namespace: default
dependsOn:
- name: nativelink-tekton-resources
9 changes: 9 additions & 0 deletions kubernetes/resources/tekton-config/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

namespace: tekton-pipelines

resources:
- routes.yaml
- tekton-config.yaml
17 changes: 17 additions & 0 deletions kubernetes/resources/tekton-config/routes.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
name: tekton-route
namespace: tekton-pipelines
spec:
parentRefs:
- sectionName: tkn-gateway
name: tkn-gateway
rules:
- matches:
- path:
value: /
backendRefs:
- name: tekton-dashboard
port: 9097
18 changes: 18 additions & 0 deletions kubernetes/resources/tekton-config/tekton-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
apiVersion: operator.tekton.dev/v1alpha1
kind: TektonConfig
metadata:
name: config
spec:
profile: all
targetNamespace: tekton-pipelines
pruner:
resources:
- pipelinerun
- taskrun
keep: 100
# Clean up every 20 minutes.
schedule: "*/20 * * * *"
pipeline:
disable-affinity-assistant: true
coschedule: pipelineruns
6 changes: 6 additions & 0 deletions kubernetes/vendor/repin.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env bash

# Tekton Operator
wget \
https://storage.googleapis.com/tekton-releases/operator/previous/v0.75.0/release.yaml \
-O tekton-operator/tekton-operator.yaml
15 changes: 15 additions & 0 deletions kubernetes/vendor/tekton-operator/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

resources:
- tekton-operator.yaml

# Disable the automatic creation of a TektonConfig as we provide our own.
patches:
- target:
kind: ConfigMap
name: tekton-config-defaults
patch: |
- op: replace
path: /data/AUTOINSTALL_COMPONENTS
value: "false"
Loading
Loading