Skip to content

Commit

Permalink
Use Spiffe Helm Chart for Spire (#496)
Browse files Browse the repository at this point in the history
* Use Spiffe Helm Chart for Spire

Signed-off-by: Brad Beck <bradley.beck@gmail.com>

* Upgrade Helm v3.7.1 -> v3.14.3

Signed-off-by: Brad Beck <bradley.beck@gmail.com>

---------

Signed-off-by: Brad Beck <bradley.beck@gmail.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
  • Loading branch information
bradbeck and kodiakhq[bot] authored May 29, 2024
1 parent 48a7fb6 commit 5f97119
Show file tree
Hide file tree
Showing 136 changed files with 9,919 additions and 1,116 deletions.
6 changes: 3 additions & 3 deletions platform/00-kubernetes-minikube-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ MINIKUBE_VERSION=v1.30.1
MINIKUBE_FILE_NAME=minikube-linux-amd64
MINIKUBE_URL=https://github.com/kubernetes/minikube/releases/download/$MINIKUBE_VERSION/$MINIKUBE_FILE_NAME

HELM_VERSION=v3.7.1
HELM_FILE_NAME=helm-v3.7.1-linux-amd64.tar.gz
HELM_VERSION=v3.14.3
HELM_FILE_NAME=helm-v3.14.3-linux-amd64.tar.gz
HELM_URL=https://get.helm.sh/$HELM_FILE_NAME
HELM_SHA256="6cd6cad4b97e10c33c978ff3ac97bb42b68f79766f1d2284cfd62ec04cd177f4"
HELM_SHA256="3c90f24e180f8c207b8a18e5ec82cb0fa49858a7a0a86e4ed52a98398681e00b"

TKN_VERSION=v0.33.0
TKN_FILE_NAME=tkn_0.33.0_Linux_x86_64.tar.gz
Expand Down
9 changes: 6 additions & 3 deletions platform/20-spire-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,12 @@ C_RESET_ALL='\033[0m'

kubectl create namespace spire --dry-run=client -o yaml | kubectl apply -f -

helm upgrade --install spire "${GIT_ROOT}/platform/vendor/spire/chart" \
--values "${GIT_ROOT}/platform/components/spire/values.yaml" \
--namespace spire --wait
helm upgrade --install -n spire spire-crds "${GIT_ROOT}/platform/vendor/spire/crd" --wait
helm upgrade --install -n spire spire "${GIT_ROOT}/platform/vendor/spire/server" \
--values "${GIT_ROOT}/platform/components/spire/values.yaml" --wait

kubectl rollout status -n spire statefulset/spire-server
kubectl rollout status -n spire daemonset/spire-agent
kubectl rollout status -n spire daemonset/spire-spiffe-csi-driver
kubectl rollout status -n spire deploy/spire-spiffe-oidc-discovery-provider

2 changes: 1 addition & 1 deletion platform/26-vault-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ fi

vault_exec read auth/jwt/config >/dev/null 2>&1 || \
vault_exec write auth/jwt/config \
oidc_discovery_url=https://spire-oidc.spire.svc.cluster.local \
oidc_discovery_url=https://spire-spiffe-oidc-discovery-provider.spire.svc.cluster.local \
default_role="spire-chains-controller"

vault_exec policy read spire-transit >/dev/null 2>&1 || \
Expand Down
2 changes: 1 addition & 1 deletion platform/components/cert-manager/spire.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
duration: 336h # 14 days
renewBefore: 168h # 7 days
dnsNames:
- spire-oidc.spire.svc.cluster.local
- spire-spiffe-oidc-discovery-provider.spire.svc.cluster.local
- oidc.example.org
- oidc
privateKey:
Expand Down
32 changes: 12 additions & 20 deletions platform/components/spire/values.yaml
Original file line number Diff line number Diff line change
@@ -1,20 +1,12 @@
server:
trustDomain: "example.org"
clusterName: frsca

agent:
kubeletSkipVerification: true

csi:
enabled: true

client:
enabled: false

oidc:
enabled: true
discoveryDomain: "spire-oidc.spire.svc.cluster.local"
# discoveryDomain: "oidc.example.org"
acme:
enabled: false
certsSecret: oidc-cert
global:
spire:
clusterName: frsca
trustDomain: example.org

spiffe-oidc-discovery-provider:
tls:
spire:
enabled: false
externalSecret:
enabled: true
secretName: oidc-cert
6 changes: 0 additions & 6 deletions platform/vendor/spire/chart/Chart.yaml

This file was deleted.

1 change: 0 additions & 1 deletion platform/vendor/spire/chart/templates/NOTES.txt

This file was deleted.

62 changes: 0 additions & 62 deletions platform/vendor/spire/chart/templates/_helpers.tpl

This file was deleted.

30 changes: 0 additions & 30 deletions platform/vendor/spire/chart/templates/agent-cluster-role.yaml

This file was deleted.

54 changes: 0 additions & 54 deletions platform/vendor/spire/chart/templates/agent-configmap.yaml

This file was deleted.

Loading

0 comments on commit 5f97119

Please sign in to comment.