working on configuring a k3s cluster
This commit is contained in:
7
ansible-5/roles/prod.k3s/files/config.yaml
Normal file
7
ansible-5/roles/prod.k3s/files/config.yaml
Normal file
@@ -0,0 +1,7 @@
|
||||
write-kubeconfig-mode: 644
|
||||
#disable:
|
||||
# - traefik
|
||||
#token: "secret"
|
||||
#node-ip: 10.0.10.22,2a05:d012:c6f:4655:d73c:c825:a184:1b75
|
||||
#cluster-cidr: 10.42.0.0/16,2001:cafe:42:0::/56
|
||||
#service-cidr: 10.43.0.0/16,2001:cafe:42:1::/112
|
||||
19
ansible-5/roles/prod.k3s/files/manifests/graphana.helm.yaml
Normal file
19
ansible-5/roles/prod.k3s/files/manifests/graphana.helm.yaml
Normal file
@@ -0,0 +1,19 @@
|
||||
apiVersion: helm.cattle.io/v1
|
||||
kind: HelmChart
|
||||
metadata:
|
||||
name: grafana
|
||||
namespace: kube-system
|
||||
spec:
|
||||
chart: stable/grafana
|
||||
targetNamespace: monitoring
|
||||
set:
|
||||
adminPassword: "NotVerySafePassword"
|
||||
valuesContent: |-
|
||||
image:
|
||||
tag: master
|
||||
env:
|
||||
GF_EXPLORE_ENABLED: true
|
||||
adminUser: admin
|
||||
sidecar:
|
||||
datasources:
|
||||
enabled: true
|
||||
26
ansible-5/roles/prod.k3s/files/manifests/mariadb.helm.yaml
Normal file
26
ansible-5/roles/prod.k3s/files/manifests/mariadb.helm.yaml
Normal file
@@ -0,0 +1,26 @@
|
||||
#https://github.com/bitnami/charts/tree/master/bitnami/mariadb
|
||||
apiVersion: helm.cattle.io/v1
|
||||
kind: HelmChart
|
||||
metadata:
|
||||
name: mariadb
|
||||
namespace: kube-system
|
||||
spec:
|
||||
chart: bitnami/mariadb
|
||||
targetNamespace: persistence
|
||||
set:
|
||||
replicaCount: 1
|
||||
valuesContent: |-
|
||||
image:
|
||||
tag: 10.5
|
||||
auth:
|
||||
rootPassword: "aifuoqibcqobcqb3"
|
||||
ingress:
|
||||
className: traefik
|
||||
hosts: sql.xai-corp.net
|
||||
extraVolumeMounts:
|
||||
- name: mysql
|
||||
mountPath: /var/lib/mysql
|
||||
extraVolumes:
|
||||
- name: mysql
|
||||
hostPath:
|
||||
path: /opt/mariadb/data
|
||||
3
ansible-5/roles/prod.k3s/files/manifests/note.txt
Normal file
3
ansible-5/roles/prod.k3s/files/manifests/note.txt
Normal file
@@ -0,0 +1,3 @@
|
||||
We can add things to the cluster by adding charts to the mainifests folder. These could be k8s resource definitions or helm charts
|
||||
|
||||
Are components removed if the chart is removed? - no
|
||||
46
ansible-5/roles/prod.k3s/files/manifests/registry.helm.yaml
Normal file
46
ansible-5/roles/prod.k3s/files/manifests/registry.helm.yaml
Normal file
@@ -0,0 +1,46 @@
|
||||
apiVersion: helm.cattle.io/v1
|
||||
kind: HelmChart
|
||||
metadata:
|
||||
name: dkregistry
|
||||
namespace: kube-system
|
||||
spec:
|
||||
chart: twuni/docker-registry
|
||||
targetNamespace: dev-tools
|
||||
set:
|
||||
adminPassword: "NotVerySafePassword"
|
||||
replicaCount: 1
|
||||
valuesContent: |-
|
||||
image:
|
||||
tag: 2.7.1
|
||||
metrics:
|
||||
enabled: true
|
||||
ingress:
|
||||
className: traefik
|
||||
hosts: dkregistry.xai-corp.net
|
||||
extraVolumeMounts:
|
||||
- name: registry-data
|
||||
mountPath: /var/lib/registry-data
|
||||
- name: registry-auth
|
||||
mountPath: /auth
|
||||
- name: registry-auth
|
||||
mountPath: /etc/docker/registry/config.yml
|
||||
- name: letsencrypt-data
|
||||
mountPath: /certs
|
||||
- name: letsencrypt-config
|
||||
mountPath: /etc/letsencrypt
|
||||
extraVolumes:
|
||||
- name: registry-data
|
||||
hostPath:
|
||||
path: /opt/shared/dkregistry/data
|
||||
- name: registry-auth
|
||||
hostPath:
|
||||
path: /opt/shared/dkregistry/auth
|
||||
- name: registry-config
|
||||
hostPath:
|
||||
path: /opt/shared/dkregistry/config/config.yml
|
||||
- name: letsencrypt-data
|
||||
hostPath:
|
||||
path: /opt/shared/letsencrypt-2
|
||||
- name: letsencrypt-config
|
||||
hostPath:
|
||||
path: /opt/shared/letsencrypt-2
|
||||
Reference in New Issue
Block a user