Skip to content
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
9 changes: 5 additions & 4 deletions .github/workflows/operator-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,10 @@ jobs:
id: kind
uses: helm/kind-action@v1
with:
version: v0.26.0
kubernetes_version: v${{ matrix.k8s-version }}
install_only: true
version: v0.29.0
node_image: kindest/node:v${{ matrix.k8s-version }}
config: operator/config/local-dev/kind-config.yaml
cluster_name: kind
# Cache build tools and dependencies for faster builds
- name: Restore cached Binaries
id: cached-binaries
Expand Down Expand Up @@ -110,7 +111,7 @@ jobs:
- name: end-to-end-tests
run: |
cd operator
GITHUB_TOKEN=${{ secrets.github_token }} make create-kind-cluster
make setup-kind-cluster
make test

# Build multi-platform container image and push to registry
Expand Down
13 changes: 6 additions & 7 deletions operator/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -192,18 +192,17 @@ else
DOCKER_AUTH_FILE=${HOME}/.config/containers/auth.json
endif

create-kind-cluster: ## deletes and creates a new kind cluster. versions is set via KIND_VERSION
ifdef CI
@echo $(GITHUB_TOKEN) | docker login ghcr.io -u $(GITHUB_ACTOR) --password-stdin
endif
kind delete cluster && kind create cluster --image=kindest/node:v$(KIND_VERSION) --config config/local-dev/kind-config.yaml
$(KUBECTL) label node/kind-worker skyhook.nvidia.com/test-node=skyhooke2e

setup-kind-cluster: ## setup kind cluster with local docker creds and skyhook namespace
## sets you local $(DOCKER_CMD) creds into a secret in kind in the skyhook namespace
$(KUBECTL) label node/kind-worker skyhook.nvidia.com/test-node=skyhooke2e
$(KUBECTL) create namespace $(SKYHOOK_NAMESPACE) --dry-run=client -o yaml | kubectl apply -f -
$(KUBECTL) create secret generic node-init-secret --type=kubernetes.io/dockerconfigjson -n $(SKYHOOK_NAMESPACE) \
--from-file=.dockerconfigjson=$(DOCKER_AUTH_FILE)

create-kind-cluster: ## deletes and creates a new kind cluster. versions is set via KIND_VERSION
kind delete cluster && kind create cluster --image=kindest/node:v$(KIND_VERSION) --config config/local-dev/kind-config.yaml
$(MAKE) setup-kind-cluster

podman-create-machine: ## creates a podman machine
podman machine stop podman-machine-default || true
podman machine rm -f podman-machine-default || true
Expand Down