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

feat: add remote cluster apply #104

Merged
merged 1 commit into from
Aug 7, 2024
Merged

feat: add remote cluster apply #104

merged 1 commit into from
Aug 7, 2024

Conversation

Skarlso
Copy link
Owner

@Skarlso Skarlso commented Aug 7, 2024

Closes #101

Adds the ability to apply CRDs into a remote cluster.

Testing:

kind create cluster --name one
kind create cluster --name external
kind get kubeconfig --internal --name external>kubeconfig.yaml
kind get kubeconfig --name external>kubeconfig-external.yaml
kubectl create secret generic kubeconfig --from-file=kubeconfig=kubeconfig.yaml
kubectl config use-context kind-one

...
tilt up

Created some secrets using the kubeconfig and used the following CRD:

apiVersion: delivery.crd-bootstrap/v1alpha1
kind: Bootstrap
metadata:
  name: bootstrap-sample
spec:
  interval: 10s
  source:
    url:
      url: https://raw.githubusercontent.com/krok-o/operator/main/config/crd/bases/delivery.krok.app_krokevents.yaml
  kubeConfig:
    secretRef:
      secretRef:
        name: kubeconfig
        key: kubeconfig

After that, verified that the remote cluster had the CRD:

k get customresourcedefinitions --kubeconfig kubeconfig-external.yaml
NAME                           CREATED AT
krokevents.delivery.krok.app   2024-08-07T06:37:47Z

borat-is-nice-high-five

@Skarlso Skarlso merged commit 2035ec9 into main Aug 7, 2024
2 checks passed
@Skarlso Skarlso deleted the add-remote-cluster branch August 7, 2024 07:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Crds into another cluster
1 participant