Skip to content

Commit 8d0ea61

Browse files
authored
Merge pull request #763 from Mirantis/ivan4th/reenable-ceph-e2e
Fix and reenable Ceph e2e
2 parents 0008256 + 592dacc commit 8d0ea61

File tree

2 files changed

+18
-12
lines changed

2 files changed

+18
-12
lines changed

.circleci/config.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -191,14 +191,13 @@ e2e: &e2e
191191
192192
- run:
193193
name: Run e2e tests
194-
# Ceph RBD tests are disabled for now because ceph/demo image is gone
195194
command: |
196195
build/portforward.sh 8080&
197196
mkdir -p ~/junit
198-
skip="-ginkgo.skip=\[Heavy\]|\[MultiCNI\]|\[Disruptive\]|RBD volumes"
197+
skip="-ginkgo.skip=\[Heavy\]|\[MultiCNI\]|\[Disruptive\]"
199198
if [[ ${CIRCLE_JOB} = e2e_multi_cni ]]; then
200199
# per-node config test requires an additional worker node
201-
skip="-ginkgo.skip=\[Heavy\]|\[Disruptive\]|Per-node configuration|RBD volumes"
200+
skip="-ginkgo.skip=\[Heavy\]|\[Disruptive\]|Per-node configuration"
202201
fi
203202
_output/virtlet-e2e-tests -test.v "${skip}" -junitOutput ~/junit/junit.xml -include-unsafe-tests=true
204203

tests/e2e/ceph_test.go

+16-9
Original file line numberDiff line numberDiff line change
@@ -191,10 +191,18 @@ func setupCeph() (string, string) {
191191
Expect(err).NotTo(HaveOccurred())
192192

193193
container.Delete()
194-
Expect(container.PullImage("docker.io/ceph/demo:tag-stable-3.0-jewel-ubuntu-16.04")).To(Succeed())
195-
Expect(container.Run("docker.io/ceph/demo:tag-stable-3.0-jewel-ubuntu-16.04",
196-
map[string]string{"MON_IP": monIP, "CEPH_PUBLIC_NETWORK": cephPublicNetwork},
197-
"host", nil, false)).To(Succeed())
194+
Expect(container.PullImage("docker.io/ceph/daemon:v3.1.0-stable-3.1-mimic-centos-7")).To(Succeed())
195+
Expect(container.Run("docker.io/ceph/daemon:v3.1.0-stable-3.1-mimic-centos-7",
196+
map[string]string{
197+
"MON_IP": monIP,
198+
"CEPH_PUBLIC_NETWORK": cephPublicNetwork,
199+
"CEPH_DEMO_UID": "foo",
200+
"CEPH_DEMO_ACCESS_KEY": "foo",
201+
"CEPH_DEMO_SECRET_KEY": "foo",
202+
"CEPH_DEMO_BUCKET": "foo",
203+
"DEMO_DAEMONS": "osd mds",
204+
},
205+
"host", nil, false, "demo")).To(Succeed())
198206

199207
cephContainerExecutor := container.Executor(false, "")
200208
By("Waiting for ceph cluster")
@@ -211,14 +219,13 @@ func setupCeph() (string, string) {
211219

212220
// Add rbd pool and volume
213221
`ceph osd pool create libvirt-pool 8 8`,
214-
`apt-get update && apt-get install -y qemu-utils 2> /dev/null`,
215-
`qemu-img create -f rbd rbd:libvirt-pool/rbd-test-image1 10M`,
216-
`qemu-img create -f rbd rbd:libvirt-pool/rbd-test-image2 10M`,
217-
`qemu-img create -f rbd rbd:libvirt-pool/rbd-test-image-pv 10M`,
222+
`rbd create rbd-test-image1 --size 10M --pool libvirt-pool --image-feature layering`,
223+
`rbd create rbd-test-image2 --size 10M --pool libvirt-pool --image-feature layering`,
224+
`rbd create rbd-test-image-pv --size 10M --pool libvirt-pool --image-feature layering`,
218225

219226
// Add user for virtlet
220227
`ceph auth get-or-create client.libvirt`,
221-
`ceph auth caps client.libvirt mon "allow *" osd "allow *" msd "allow *"`,
228+
`ceph auth caps client.libvirt mon "allow *" osd "allow *"`,
222229
`ceph auth get-key client.libvirt`,
223230
}
224231
for _, cmd := range commands {

0 commit comments

Comments
 (0)