Skip to content

Commit

Permalink
feat(k8s): add istio system
Browse files Browse the repository at this point in the history
  • Loading branch information
Collinbrown95 committed Nov 14, 2023
1 parent 42091d5 commit 4947408
Show file tree
Hide file tree
Showing 6 changed files with 148 additions and 0 deletions.
15 changes: 15 additions & 0 deletions k8s/istio-system/gateway.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: networking.istio.io/v1beta1
kind: Gateway
metadata:
name: public-gateway
namespace: istio-system
spec:
selector:
istio: gateway
servers:
- port:
number: 80
name: http
protocol: HTTP
hosts:
- "*"
9 changes: 9 additions & 0 deletions k8s/istio-system/istio-version.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: istio-version
namespace: flux-system
annotations:
kustomize.toolkit.fluxcd.io/ssa: merge
data:
version: 1.19.3
96 changes: 96 additions & 0 deletions k8s/istio-system/istio.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
apiVersion: source.toolkit.fluxcd.io/v1beta1
kind: HelmRepository
metadata:
name: istio
namespace: istio-system
labels:
app.kubernetes.io/part-of: istio
spec:
interval: 1h0m0s
url: https://istio-release.storage.googleapis.com/charts
---
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: istio-base
namespace: istio-system
labels:
app.kubernetes.io/part-of: istio
spec:
releaseName: istio-base
install:
crds: Create
upgrade:
crds: CreateReplace
chart:
spec:
version: "${version}"
chart: base
sourceRef:
kind: HelmRepository
name: istio
interval: 1h0m0s
---
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: istiod
namespace: istio-system
labels:
app.kubernetes.io/part-of: istio
spec:
releaseName: istiod
dependsOn:
- name: istio-base
chart:
spec:
version: "${version}"
chart: istiod
sourceRef:
kind: HelmRepository
name: istio
interval: 1h0m0s
values:
global:
istioNamespace: istio-system
proxy:
resources:
requests:
cpu: 10m
memory: 16Mi
pilot:
autoscaleEnabled: false
resources:
requests:
cpu: 100m
memory: 128Mi
---
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: istio-gateway
namespace: istio-system
labels:
app.kubernetes.io/part-of: istio
spec:
releaseName: istio-gateway
dependsOn:
- name: istio-base
- name: istiod
chart:
spec:
version: "${version}"
chart: gateway
sourceRef:
kind: HelmRepository
name: istio
interval: 1h0m0s
values:
autoscaling:
enabled: false
resources:
requests:
cpu: 10m
memory: 128Mi
service:
type: "${service:=LoadBalancer}"
7 changes: 7 additions & 0 deletions k8s/istio-system/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ./ns.yaml
- ./istio-version.yaml
- ./istio.yaml
- ./gateway.yaml
4 changes: 4 additions & 0 deletions k8s/istio-system/ns.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
apiVersion: v1
kind: Namespace
metadata:
name: istio-system
17 changes: 17 additions & 0 deletions k8s/istio-system/sync.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1beta2
kind: Kustomization
metadata:
name: istio-system
namespace: flux-system
spec:
interval: 10m0s
path: ./k8s/istio-system
prune: true
wait: true
sourceRef:
kind: GitRepository
name: flux-system
postBuild:
substituteFrom:
- kind: ConfigMap
name: istio-version

0 comments on commit 4947408

Please sign in to comment.