Skip to content

Commit

Permalink
Manifest changes
Browse files Browse the repository at this point in the history
  • Loading branch information
YashwantGohokar committed Jun 28, 2024
1 parent b6f1890 commit e25ffcd
Show file tree
Hide file tree
Showing 13 changed files with 96 additions and 118 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ WORKDIR $SRC

RUN COMPONENT=${COMPONENT} make clean build

FROM oraclelinux:8-slim
FROM oraclelinux:8

COPY --from=0 /go/src/github.com/oracle/oci-cloud-controller-manager/dist/* /usr/local/bin/
COPY --from=0 /go/src/github.com/oracle/oci-cloud-controller-manager/image/* /usr/local/bin/
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ else
VERSION ?= ${VERSION}
endif

RELEASE = v1.28.0
RELEASE = v1.29.0

GOOS ?= linux
ARCH ?= amd64
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ spec:
path: /etc/kubernetes
containers:
- name: oci-cloud-controller-manager
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: ghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
command: ["/usr/local/bin/oci-cloud-controller-manager"]
args:
- --cloud-config=/etc/oci/cloud-provider.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ spec:
node-role.kubernetes.io/control-plane: ""
containers:
- name: csi-volume-provisioner
image: registry.k8s.io/sig-storage/csi-provisioner:v3.6.0
image: registry.k8s.io/sig-storage/csi-provisioner:v5.0.1
args:
- --csi-address=/var/run/shared-tmpfs/csi.sock
- --volume-name-prefix=csi
Expand All @@ -37,7 +37,7 @@ spec:
- mountPath: /var/run/shared-tmpfs
name: shared-tmpfs
- name: csi-fss-volume-provisioner
image: registry.k8s.io/sig-storage/csi-provisioner:v3.6.0
image: registry.k8s.io/sig-storage/csi-provisioner:v5.0.1
args:
- --csi-address=/var/run/shared-tmpfs/csi-fss.sock
- --volume-name-prefix=csi-fss
Expand All @@ -52,7 +52,7 @@ spec:
- mountPath: /var/run/shared-tmpfs
name: shared-tmpfs
- name: csi-attacher
image: registry.k8s.io/sig-storage/csi-attacher:v4.4.0
image: registry.k8s.io/sig-storage/csi-attacher:v4.6.1
args:
- --csi-address=/var/run/shared-tmpfs/csi.sock
- --timeout=120s
Expand All @@ -65,7 +65,7 @@ spec:
- mountPath: /var/run/shared-tmpfs
name: shared-tmpfs
- name: csi-resizer
image: registry.k8s.io/sig-storage/csi-resizer:v1.9.0
image: registry.k8s.io/sig-storage/csi-resizer:v1.11.1
args:
- --csi-address=/var/run/shared-tmpfs/csi.sock
- --leader-election
Expand Down Expand Up @@ -96,7 +96,7 @@ spec:
- --fss-csi-endpoint=unix://var/run/shared-tmpfs/csi-fss.sock
command:
- /usr/local/bin/oci-csi-controller-driver
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: gghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
imagePullPolicy: IfNotPresent
volumeMounts:
- name: config
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ spec:
fieldPath: spec.nodeName
- name: PATH
value: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/host/usr/bin:/host/sbin
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: ghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
securityContext:
privileged: true
volumeMounts:
Expand Down
4 changes: 2 additions & 2 deletions manifests/flexvolume-driver/oci-flexvolume-driver.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ spec:
secretName: oci-flexvolume-driver
containers:
- name: oci-flexvolume-driver
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: ghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
command: ["/usr/local/bin/install.py", "-c", "/tmp/config.yaml"]
securityContext:
privileged: true
Expand Down Expand Up @@ -76,7 +76,7 @@ spec:
type: DirectoryOrCreate
containers:
- name: oci-flexvolume-driver
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: ghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
command: ["/usr/local/bin/install.py"]
securityContext:
privileged: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ spec:
secretName: oci-volume-provisioner
containers:
- name: oci-volume-provisioner
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: ghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
command: ["/usr/local/bin/oci-volume-provisioner"]
env:
- name: NODE_NAME
Expand Down
2 changes: 1 addition & 1 deletion manifests/volume-provisioner/oci-volume-provisioner.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ spec:
secretName: oci-volume-provisioner
containers:
- name: oci-volume-provisioner
image: ghcr.io/oracle/cloud-provider-oci:v1.28.0
image: ghcr.io/yashwantgohokar/cloud-provider-oci:v1.29.0
command: ["/usr/local/bin/oci-volume-provisioner"]
env:
- name: NODE_NAME
Expand Down
164 changes: 82 additions & 82 deletions test/e2e/cloud-provider-oci/csi_snapshot_restore.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,88 +37,88 @@ const (
var _ = Describe("Snapshot Creation and Restore", func() {
f := framework.NewBackupFramework("snapshot-restore")

Context("[cloudprovider][storage][csi][snapshot][restore]", func() {
tests := []struct{
attachmentType string
backupType string
fsType string
}{
{framework.AttachmentTypeParavirtualized, framework.BackupTypeIncremental, ""},
{framework.AttachmentTypeParavirtualized, framework.BackupTypeFull, ""},
{framework.AttachmentTypeISCSI, framework.BackupTypeIncremental, ""},
{framework.AttachmentTypeISCSI, framework.BackupTypeFull, ""},
{framework.AttachmentTypeISCSI, framework.BackupTypeIncremental, "xfs"},
{framework.AttachmentTypeParavirtualized, framework.BackupTypeFull, "ext3"},
}
for _, entry := range tests {
entry := entry
testName := "Should be able to create and restore " + entry.backupType + " snapshot from " + entry.attachmentType + " volume "
if entry.fsType != "" {
testName += " with " + entry.fsType + " fsType"
}
It(testName, func() {
scParams := map[string]string{framework.AttachmentType: entry.attachmentType}
vscParams := map[string]string{framework.BackupType: entry.backupType}
scParams[framework.FstypeKey] = entry.fsType
testSnapshotAndRestore(f, scParams, vscParams)
})
}
It("FS should get expanded when a PVC is restored with a lesser size backup (iscsi)", func() {
checkOrInstallCRDs(f)
scParams := map[string]string{framework.AttachmentType: framework.AttachmentTypeISCSI}
vscParams := map[string]string{framework.BackupType: framework.BackupTypeFull}
pvcJig := framework.NewPVCTestJig(f.ClientSet, "csi-snapshot-restore-e2e-tests")
pvcJig.InitialiseSnapClient(f.SnapClientSet)

scName := f.CreateStorageClassOrFail(f.Namespace.Name, BVDriverName, scParams, pvcJig.Labels, BindingModeWaitForFirstConsumer, true, ReclaimPolicyDelete, nil)
pvc := pvcJig.CreateAndAwaitPVCOrFailCSI(f.Namespace.Name, framework.MinVolumeBlock, scName, nil, v1.PersistentVolumeFilesystem, v1.ReadWriteOnce, v1.ClaimPending)

_ = pvcJig.NewPodForCSI("pod-original", f.Namespace.Name, pvc.Name, setupF.AdLabel)

time.Sleep(60 * time.Second) //waiting for pod to up and running

vscName := f.CreateVolumeSnapshotClassOrFail(f.Namespace.Name, BVDriverName, vscParams, ReclaimPolicyDelete)
vs := pvcJig.CreateAndAwaitVolumeSnapshotOrFail(f.Namespace.Name, vscName, pvc.Name, nil)

pvcRestore := pvcJig.CreateAndAwaitPVCOrFailSnapshotSource(f.Namespace.Name, framework.MaxVolumeBlock, scName, vs.Name, v1.ClaimPending, nil)
podRestoreName := pvcJig.NewPodForCSI("pod-restored", f.Namespace.Name, pvcRestore.Name, setupF.AdLabel)

time.Sleep(60 * time.Second) //waiting for pod to up and running

pvcJig.CheckUsableVolumeSizeInsidePod(f.Namespace.Name, podRestoreName, "99G")

f.VolumeIds = append(f.VolumeIds, pvc.Spec.VolumeName)
_ = f.DeleteVolumeSnapshotClass(f.Namespace.Name)
_ = f.DeleteStorageClass(f.Namespace.Name)
})
It("FS should get expanded when a PVC is restored with a lesser size backup (paravirtualized)", func() {
checkOrInstallCRDs(f)
scParams := map[string]string{framework.AttachmentType: framework.AttachmentTypeParavirtualized}
vscParams := map[string]string{framework.BackupType: framework.BackupTypeFull}
pvcJig := framework.NewPVCTestJig(f.ClientSet, "csi-snapshot-restore-e2e-tests")
pvcJig.InitialiseSnapClient(f.SnapClientSet)

scName := f.CreateStorageClassOrFail(f.Namespace.Name, BVDriverName, scParams, pvcJig.Labels, BindingModeWaitForFirstConsumer, true, ReclaimPolicyDelete, nil)
pvc := pvcJig.CreateAndAwaitPVCOrFailCSI(f.Namespace.Name, framework.MinVolumeBlock, scName, nil, v1.PersistentVolumeFilesystem, v1.ReadWriteOnce, v1.ClaimPending)

_ = pvcJig.NewPodForCSI("pod-original", f.Namespace.Name, pvc.Name, setupF.AdLabel)

time.Sleep(60 * time.Second) //waiting for pod to up and running

vscName := f.CreateVolumeSnapshotClassOrFail(f.Namespace.Name, BVDriverName, vscParams, ReclaimPolicyDelete)
vs := pvcJig.CreateAndAwaitVolumeSnapshotOrFail(f.Namespace.Name, vscName, pvc.Name, nil)

pvcRestore := pvcJig.CreateAndAwaitPVCOrFailSnapshotSource(f.Namespace.Name, framework.MaxVolumeBlock, scName, vs.Name, v1.ClaimPending, nil)
podRestoreName := pvcJig.NewPodForCSI("pod-restored", f.Namespace.Name, pvcRestore.Name, setupF.AdLabel)

time.Sleep(60 * time.Second) //waiting for pod to up and running

pvcJig.CheckUsableVolumeSizeInsidePod(f.Namespace.Name, podRestoreName, "99G")

f.VolumeIds = append(f.VolumeIds, pvc.Spec.VolumeName)
_ = f.DeleteVolumeSnapshotClass(f.Namespace.Name)
_ = f.DeleteStorageClass(f.Namespace.Name)
})
Context("[cloudprovider][storage][csi][snapshot][restore][test1]", func() {
//tests := []struct{
// attachmentType string
// backupType string
// fsType string
//}{
// {framework.AttachmentTypeParavirtualized, framework.BackupTypeIncremental, ""},
// {framework.AttachmentTypeParavirtualized, framework.BackupTypeFull, ""},
// {framework.AttachmentTypeISCSI, framework.BackupTypeIncremental, ""},
// {framework.AttachmentTypeISCSI, framework.BackupTypeFull, ""},
// {framework.AttachmentTypeISCSI, framework.BackupTypeIncremental, "xfs"},
// {framework.AttachmentTypeParavirtualized, framework.BackupTypeFull, "ext3"},
//}
//for _, entry := range tests {
// entry := entry
// testName := "Should be able to create and restore " + entry.backupType + " snapshot from " + entry.attachmentType + " volume "
// if entry.fsType != "" {
// testName += " with " + entry.fsType + " fsType"
// }
// It(testName, func() {
// scParams := map[string]string{framework.AttachmentType: entry.attachmentType}
// vscParams := map[string]string{framework.BackupType: entry.backupType}
// scParams[framework.FstypeKey] = entry.fsType
// testSnapshotAndRestore(f, scParams, vscParams)
// })
//}
//It("FS should get expanded when a PVC is restored with a lesser size backup (iscsi)", func() {
// checkOrInstallCRDs(f)
// scParams := map[string]string{framework.AttachmentType: framework.AttachmentTypeISCSI}
// vscParams := map[string]string{framework.BackupType: framework.BackupTypeFull}
// pvcJig := framework.NewPVCTestJig(f.ClientSet, "csi-snapshot-restore-e2e-tests")
// pvcJig.InitialiseSnapClient(f.SnapClientSet)
//
// scName := f.CreateStorageClassOrFail(f.Namespace.Name, BVDriverName, scParams, pvcJig.Labels, BindingModeWaitForFirstConsumer, true, ReclaimPolicyDelete, nil)
// pvc := pvcJig.CreateAndAwaitPVCOrFailCSI(f.Namespace.Name, framework.MinVolumeBlock, scName, nil, v1.PersistentVolumeFilesystem, v1.ReadWriteOnce, v1.ClaimPending)
//
// _ = pvcJig.NewPodForCSI("pod-original", f.Namespace.Name, pvc.Name, setupF.AdLabel)
//
// time.Sleep(60 * time.Second) //waiting for pod to up and running
//
// vscName := f.CreateVolumeSnapshotClassOrFail(f.Namespace.Name, BVDriverName, vscParams, ReclaimPolicyDelete)
// vs := pvcJig.CreateAndAwaitVolumeSnapshotOrFail(f.Namespace.Name, vscName, pvc.Name, nil)
//
// pvcRestore := pvcJig.CreateAndAwaitPVCOrFailSnapshotSource(f.Namespace.Name, framework.MaxVolumeBlock, scName, vs.Name, v1.ClaimPending, nil)
// podRestoreName := pvcJig.NewPodForCSI("pod-restored", f.Namespace.Name, pvcRestore.Name, setupF.AdLabel)
//
// time.Sleep(60 * time.Second) //waiting for pod to up and running
//
// pvcJig.CheckUsableVolumeSizeInsidePod(f.Namespace.Name, podRestoreName, "99G")
//
// f.VolumeIds = append(f.VolumeIds, pvc.Spec.VolumeName)
// _ = f.DeleteVolumeSnapshotClass(f.Namespace.Name)
// _ = f.DeleteStorageClass(f.Namespace.Name)
//})
//It("FS should get expanded when a PVC is restored with a lesser size backup (paravirtualized)", func() {
// checkOrInstallCRDs(f)
// scParams := map[string]string{framework.AttachmentType: framework.AttachmentTypeParavirtualized}
// vscParams := map[string]string{framework.BackupType: framework.BackupTypeFull}
// pvcJig := framework.NewPVCTestJig(f.ClientSet, "csi-snapshot-restore-e2e-tests")
// pvcJig.InitialiseSnapClient(f.SnapClientSet)
//
// scName := f.CreateStorageClassOrFail(f.Namespace.Name, BVDriverName, scParams, pvcJig.Labels, BindingModeWaitForFirstConsumer, true, ReclaimPolicyDelete, nil)
// pvc := pvcJig.CreateAndAwaitPVCOrFailCSI(f.Namespace.Name, framework.MinVolumeBlock, scName, nil, v1.PersistentVolumeFilesystem, v1.ReadWriteOnce, v1.ClaimPending)
//
// _ = pvcJig.NewPodForCSI("pod-original", f.Namespace.Name, pvc.Name, setupF.AdLabel)
//
// time.Sleep(60 * time.Second) //waiting for pod to up and running
//
// vscName := f.CreateVolumeSnapshotClassOrFail(f.Namespace.Name, BVDriverName, vscParams, ReclaimPolicyDelete)
// vs := pvcJig.CreateAndAwaitVolumeSnapshotOrFail(f.Namespace.Name, vscName, pvc.Name, nil)
//
// pvcRestore := pvcJig.CreateAndAwaitPVCOrFailSnapshotSource(f.Namespace.Name, framework.MaxVolumeBlock, scName, vs.Name, v1.ClaimPending, nil)
// podRestoreName := pvcJig.NewPodForCSI("pod-restored", f.Namespace.Name, pvcRestore.Name, setupF.AdLabel)
//
// time.Sleep(60 * time.Second) //waiting for pod to up and running
//
// pvcJig.CheckUsableVolumeSizeInsidePod(f.Namespace.Name, podRestoreName, "99G")
//
// f.VolumeIds = append(f.VolumeIds, pvc.Spec.VolumeName)
// _ = f.DeleteVolumeSnapshotClass(f.Namespace.Name)
// _ = f.DeleteStorageClass(f.Namespace.Name)
//})
It("Should be able to create and restore a snapshot from a backup(static case)", func() {
checkOrInstallCRDs(f)
scParams := map[string]string{framework.AttachmentType: framework.AttachmentTypeISCSI}
Expand Down
1 change: 0 additions & 1 deletion test/e2e/cloud-provider-oci/csi_volume_creation.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ var _ = Describe("CSI Volume Creation", func() {
// volume name duplicate should not exist
for _, volume := range volumes {
framework.Logf("volume details %v :", volume)
framework.Logf("cluster ocid from setup is %s", setupF.ClusterOcid)
if setupF.AddOkeSystemTags && !framework.HasOkeSystemTags(volume.SystemTags) {
framework.Failf("the resource %s is expected to have oke system tags", *volume.Id)
}
Expand Down
6 changes: 1 addition & 5 deletions test/e2e/cloud-provider-oci/load_balancer.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,15 @@ package e2e

import (
"context"
"encoding/json"
"fmt"
"net"
"reflect"
"strconv"
"strings"

. "github.com/onsi/ginkgo"
. "github.com/onsi/gomega"
cloudprovider "github.com/oracle/oci-cloud-controller-manager/pkg/cloudprovider/providers/oci"
sharedfw "github.com/oracle/oci-cloud-controller-manager/test/e2e/framework"
"github.com/oracle/oci-go-sdk/v65/containerengine"
"github.com/oracle/oci-go-sdk/v65/core"

"go.uber.org/zap"
Expand Down Expand Up @@ -59,7 +56,7 @@ var _ = Describe("Service [Slow]", func() {
},
},
}
Context("[cloudprovider][ccm][lb][SL][system-tags]", func() {
Context("[cloudprovider][ccm][lb][SL][system-tags][test]", func() {
It("should be possible to create and mutate a Service type:LoadBalancer (change nodeport) [Canary]", func() {
for _, test := range basicTestArray {
By("Running test for: " + test.lbType)
Expand Down Expand Up @@ -120,7 +117,6 @@ var _ = Describe("Service [Slow]", func() {
loadBalancer, err := f.Client.LoadBalancer(zap.L().Sugar(), lbType, "", nil).GetLoadBalancerByName(ctx, compartmentId, lbName)
sharedfw.ExpectNoError(err)
sharedfw.Logf("Loadbalancer details %v:", loadBalancer)
sharedfw.Logf("cluster ocid from setup is %s", setupF.ClusterOcid)
if setupF.AddOkeSystemTags && !sharedfw.HasOkeSystemTags(loadBalancer.SystemTags) {
sharedfw.Failf("Loadbalancer is expected to have the system tags")
}
Expand Down
4 changes: 0 additions & 4 deletions test/e2e/cloud-provider-oci/setup.go
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package e2e

import (
"time"

"github.com/onsi/ginkgo"
. "github.com/onsi/gomega"
sharedfw "github.com/oracle/oci-cloud-controller-manager/test/e2e/framework"
oke "github.com/oracle/oci-go-sdk/v65/containerengine"
)

var setupF *sharedfw.Framework
Expand Down
13 changes: 0 additions & 13 deletions test/e2e/framework/framework.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,26 +15,13 @@
package framework

import (
"context"
"flag"
"fmt"
"io/ioutil"
"math/rand"
"os"
"strconv"
"strings"
"time"

imageutils "k8s.io/kubernetes/test/utils/image"

"github.com/oracle/oci-cloud-controller-manager/pkg/cloudprovider/providers/oci/config"

. "github.com/onsi/gomega"
"github.com/oracle/oci-go-sdk/v65/common"
oke "github.com/oracle/oci-go-sdk/v65/containerengine"
"github.com/oracle/oci-go-sdk/v65/core"
"github.com/oracle/oci-go-sdk/v65/identity"
"gopkg.in/yaml.v2"
)

const (
Expand Down

0 comments on commit e25ffcd

Please sign in to comment.