Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
64 commits
Select commit Hold shift + click to select a range
9d7d45d
added integration with the image-builder kubevirt image
Apr 27, 2022
5850b33
Merge pull request #108 from isaacdorfman/image-builder-integration
k8s-ci-robot Apr 27, 2022
c5b9ccc
kubevirtci: Add option to interact with the tenant cluster and improv…
nirarg Apr 28, 2022
fa1c7cf
Add failure printout to the e2e test RunCmd function
nunnatsa May 2, 2022
f89a85c
Merge pull request #134 from nunnatsa/debug-e2e
k8s-ci-robot May 2, 2022
93595d8
added docs for creating the image-builder image
May 3, 2022
e5c71d0
clusterctl integration
May 10, 2022
7f597e1
Fixed a linting problem
May 10, 2022
879a4cb
Merge pull request #113 from isaacdorfman/clusterctl-integration
k8s-ci-robot May 10, 2022
682b649
Merge pull request #135 from isaacdorfman/image-builder-docs
k8s-ci-robot May 10, 2022
cf80b5a
Move to golang 1.18
nunnatsa May 12, 2022
a6326da
Merge pull request #136 from nunnatsa/move-to-go-1.18
k8s-ci-robot May 12, 2022
27cedcf
Merge pull request #133 from nirarg/kubevirtci-tenant-access
k8s-ci-robot May 24, 2022
ed7eb9e
Add namespace to kubectl-tenant command
davidvossel May 25, 2022
0857b5f
Add ssh commands for infra and tenant nodes
davidvossel May 25, 2022
f01885d
add kubevirtci destroy-cluster command
davidvossel May 25, 2022
60a0162
make separate kubevirtci command for simulating external clusters
davidvossel May 25, 2022
4c4743d
Merge pull request #140 from davidvossel/kubevirtci-updates
k8s-ci-robot May 26, 2022
62c6aae
Add tenant cluster verification to createcluster test
nirarg May 17, 2022
c620757
Add kubevirtci option for installing metallb
davidvossel May 26, 2022
f706284
Adds command to curl a load balancer within infra cluster
davidvossel May 26, 2022
8099067
Add kubevirtci command to install capk from upstream release
davidvossel May 26, 2022
138541e
Add kubevirtci function to clean local cache
davidvossel May 26, 2022
435fc16
Merge pull request #141 from davidvossel/kubevirtci-metal-lb
k8s-ci-robot May 30, 2022
3457e8e
Merge pull request #139 from nirarg/e2e-test
k8s-ci-robot May 31, 2022
a6e4584
add install calico to kubevirtci and update cluster-up git hash
davidvossel Jun 1, 2022
7880b04
offset tenant network settings from default infra kubeadm settings
davidvossel Jun 1, 2022
7c2ee63
Install cni and verify pod/node status in e2e tests
davidvossel Jun 1, 2022
7bc78d3
Merge pull request #143 from davidvossel/network-fixes
k8s-ci-robot Jun 9, 2022
d534fcb
Fix flaky e2e test
davidvossel Jun 29, 2022
3fbdad9
Merge pull request #144 from davidvossel/e2e-test-fix
k8s-ci-robot Jun 29, 2022
cce88a0
Revert "Fix flaky e2e test"
davidvossel Jul 12, 2022
41c77a7
Merge pull request #148 from davidvossel/revert-144-e2e-test-fix
k8s-ci-robot Jul 12, 2022
d463f34
Pin kubevirtci to a kubevirt release to prevent CI regressions
davidvossel Jul 21, 2022
33930bb
Update to k8s 1.22 guest cluster image
davidvossel Jul 21, 2022
cbc09ac
Reduce memory usage by using local storage provider
davidvossel Jul 22, 2022
1dd6434
Merge pull request #155 from davidvossel/pin-kubevirt-release
k8s-ci-robot Jul 22, 2022
f108640
[e2e tests] Cover creating tenant clusters in external infra clusters…
agradouski Apr 15, 2022
d6c15cf
Enable specifying namespace where VM and VMI are created.
pjaton Jul 19, 2022
239dbcc
Search for external VM to delete in correct namespace.
pjaton Jul 19, 2022
5528680
Avoid reporting not-found errors when patching resources under deletion.
pjaton Jul 22, 2022
821b0a8
Merge pull request #151 from pjaton/fix-external-deletion
k8s-ci-robot Jul 25, 2022
749147a
Merge pull request #132 from agradouski/issue/90
k8s-ci-robot Jul 25, 2022
1aeca51
Merge pull request #157 from pjaton/fix-patch-of-deleted-failure
k8s-ci-robot Jul 25, 2022
46a88fa
Add capk user properly when users already defined.
pjaton Jul 25, 2022
a167f93
Select kubeconfig current context namespace before 'default'.
pjaton Jul 25, 2022
a8097c4
Merge pull request #160 from pjaton/fix-namespace-logic
k8s-ci-robot Jul 26, 2022
7229ee4
kubevirtci: Wait for cluster and calico
qinqon Jul 21, 2022
ab5ec82
Copy Kubeadm userdata secret labels to CAPK secret.
pjaton Jul 26, 2022
fe229f7
Merge pull request #154 from qinqon/wait-for-tenant
k8s-ci-robot Jul 28, 2022
528668f
Use gomega matcher to check labels
pjaton Jul 28, 2022
58dcd70
Merge pull request #159 from pjaton/fix-capk-user-add
k8s-ci-robot Jul 29, 2022
abde9dd
Refactor setup-scheme into shared functions.
pjaton Aug 1, 2022
a9e7e11
Look for the infrastructure secret in the owner namespace by default.
pjaton Aug 1, 2022
f648582
Merge pull request #164 from pjaton/add-secret-labels
k8s-ci-robot Aug 1, 2022
5aa3a3d
Merge pull request #167 from pjaton/fix-infra-secret-lookup
k8s-ci-robot Aug 1, 2022
160f5dc
Graceful deletion of a VirtualMachineInstance
nunnatsa Jun 30, 2022
b9d14c9
Apply code-review comments
nunnatsa Jul 4, 2022
210fd52
Drain node: add timeout
nunnatsa Jul 11, 2022
d8b2b98
Add VMI eviction functional test
nunnatsa Jul 12, 2022
8c89b7c
fix bug in the vmi eviction controller - wrong predicate
nunnatsa Jul 28, 2022
8a5e0df
Fix code review comments
nunnatsa Aug 2, 2022
48c632e
Merge pull request #145 from nunnatsa/drain-node
k8s-ci-robot Aug 3, 2022
b0ddcf1
Merge remote-tracking branch 'auto-sync-script-upstream/main' into au…
nunnatsa Aug 4, 2022
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
2 changes: 1 addition & 1 deletion .github/workflows/clusterkubevirtadm-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.17
go-version: 1.18
- name: Checkout code
uses: actions/checkout@v2
- name: Test
Expand Down
73 changes: 73 additions & 0 deletions .github/workflows/create_release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
on:
push:
tags:
- "v*"

name: Upload Release Asset

jobs:
build-and-push-image:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: build image
shell: bash
env:
QUAY_TOKEN: ${{secrets.QUAY_TOKEN}}
REGISTRY: "quay.io/capk"
TAG: ${{ github.ref_name }}
run: |
echo $QUAY_TOKEN | docker login -u="capk+capk_robot" quay.io --password-stdin
make docker-build
make docker-push
build:
name: Upload Release Asset
needs: build-and-push-image
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: '1.18'
- name: Install kustomize
run: curl -s "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" | bash
- name: Create infrastructure components
env:
REGISTRY: "quay.io/capk"
IMAGE_NAME: "capk-manager-amd64"
TAG: ${{ github.ref_name }}
run: |
make create-infrastructure-components
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false
- name: Upload infrastructure-components.yaml
id: upload-infrastructure-components
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./infrastructure-components.yaml
asset_name: infrastructure-components.yaml
asset_content_type: text/plain
- name: Upload metadata.yaml
id: upload-metadata
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./metadata.yaml
asset_name: metadata.yaml
asset_content_type: text/plain
4 changes: 2 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ jobs:
if: (github.repository == 'kubernetes-sigs/cluster-api-provider-kubevirt')
strategy:
matrix:
go-version: [1.17.x]
go-version: [1.18.x]
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
Expand All @@ -27,7 +27,7 @@ jobs:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.17.x
go-version: 1.18.x
- name: Checkout code
uses: actions/checkout@v2
- name: Test with coverage
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ cluster-up/
hack/tools/bin/
bin/
.idea/
infrastructure-components.yaml
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

# Build the manager binary
# Run this with docker build --build-arg builder_image=<golang:x.y.z>
ARG builder_image=golang:1.17.2
ARG builder_image=golang:1.18.2
FROM ${builder_image} as builder
WORKDIR /workspace

Expand Down
24 changes: 17 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
# If you update this file, please follow:
# https://suva.sh/posts/well-documented-makefiles/

ROOT = $$GOPATH/pkg/mod/sigs.k8s.io/cluster-api@v0.3.11-0.20210525210043-6c7878e7b4a9
ROOT = $$(go env GOPATH)/pkg/mod/sigs.k8s.io/cluster-api@v0.3.11-0.20210525210043-6c7878e7b4a9

.DEFAULT_GOAL:=help
TARGET ?= target
Expand Down Expand Up @@ -50,13 +50,11 @@ endif
CONTROLLER_GEN := $(abspath $(TOOLS_BIN_DIR)/controller-gen)
CONVERSION_GEN := $(abspath $(TOOLS_BIN_DIR)/conversion-gen)
GOTESTSUM := $(abspath $(TOOLS_BIN_DIR)/gotestsum)
KUSTOMIZE := $(abspath $(TOOLS_BIN_DIR)/kustomize)

$(KUSTOMIZE): # Build kustomize from tools folder.
$(MAKE) -C $(ROOT) kustomize
KUSTOMIZE_IMAGE = k8s.gcr.io/kustomize/kustomize:v3.8.7
KUSTOMIZE ?= docker run $(KUSTOMIZE_IMAGE)

# Define Docker related variables. Releases should modify and double check these vars.
REGISTRY ?= localhost:5000
REGISTRY ?= 127.0.0.1:5000
IMAGE_NAME ?= capk-manager
CONTROLLER_IMG ?= $(REGISTRY)/$(IMAGE_NAME)
ARCH ?= amd64
Expand Down Expand Up @@ -187,7 +185,7 @@ modules: ## Runs go mod to ensure modules are up to date.
.PHONY: docker-pull-prerequisites
docker-pull-prerequisites:
docker pull docker.io/docker/dockerfile:1.1-experimental
docker pull docker.io/library/golang:1.17.2
docker pull docker.io/library/golang:1.18.2
docker pull gcr.io/distroless/static:latest

.PHONY: docker-build
Expand Down Expand Up @@ -244,6 +242,18 @@ else
sed -i -e 's@imagePullPolicy: .*@imagePullPolicy: '"$(PULL_POLICY)"'@' ./config/default/manager_pull_policy.yaml
endif

## --------------------------------------
## Deployment
## --------------------------------------
##> infrastructure-components.yaml
set_controller_image:
echo setting controller image to be ${CONTROLLER_IMG}:${TAG}
cd config/default && kustomize edit set image controller=${CONTROLLER_IMG}:${TAG}

create-infrastructure-components: generate-manifests set_controller_image
kustomize build config/default > infrastructure-components.yaml


## --------------------------------------
## Cleanup / Verification
## --------------------------------------
Expand Down
6 changes: 5 additions & 1 deletion api/v1alpha1/kubevirtcluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,17 @@ const (
ClusterFinalizer = "kubevirtcluster.infrastructure.cluster.x-k8s.io"
)

const (
const ( //labels
KubevirtMachineNameLabel = "capk.cluster.x-k8s.io/kubevirt-machine-name"
KubevirtMachineNamespaceLabel = "capk.cluster.x-k8s.io/kubevirt-machine-namespace"

KubevirtMachineVMTerminalLabel = "capk.cluster.x-k8s.io/vm-is-terminal"
)

const ( // annotations
VmiDeletionGraceTime = "capk.cluster.x-k8s.io/vmi-deletion-grace-time"
)

// KubevirtClusterSpec defines the desired state of KubevirtCluster.
type KubevirtClusterSpec struct {
// INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
Expand Down
1 change: 1 addition & 0 deletions api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion clusterctl-settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "infrastructure-kubevirt",
"name": "kubevirt",
"config": {
"componentsFile": "infrastructure-components.yaml",
"nextVersion": "v0.1.0"
Expand Down
Loading