-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add an overlay using rook-ceph-block pvc. We deploy and both test in parallel. Signed-off-by: Nir Soffer <[email protected]>
- Loading branch information
Showing
10 changed files
with
169 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,5 +5,4 @@ | |
resources: | ||
- namespace.yaml | ||
- pvc.yaml | ||
- deploy.yaml | ||
namespace: volsync-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# SPDX-FileCopyrightText: The RamenDR authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
# yamllint disable rule:line-length | ||
--- | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
labels: | ||
appname: busybox | ||
name: busybox | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
appname: busybox | ||
template: | ||
metadata: | ||
labels: | ||
appname: busybox | ||
spec: | ||
containers: | ||
- image: quay.io/nirsof/busybox:stable | ||
imagePullPolicy: IfNotPresent | ||
name: busybox | ||
command: | ||
- sh | ||
- -c | ||
- | | ||
trap exit TERM | ||
image_size=1073741824 # 1Gi | ||
block_size=512 | ||
blocks=$((image_size/block_size)) | ||
block_number=0 | ||
while true; do | ||
data=$(date) | ||
echo $data | ||
echo $data | dd of=/dev/xvda bs=$block_size seek=$block_number status=none conv=fsync | ||
sleep 10 & | ||
wait | ||
block_number=$((block_number+1)) | ||
if [ $block_number -ge $blocks ]; then | ||
block_number=0; | ||
fi | ||
done | ||
volumeDevices: | ||
- name: volume | ||
devicePath: /dev/xvda | ||
volumes: | ||
- name: volume | ||
persistentVolumeClaim: | ||
claimName: busybox-pvc | ||
securityContext: | ||
runAsUser: 10000 | ||
runAsGroup: 10000 | ||
fsGroup: 10000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# SPDX-FileCopyrightText: The RamenDR authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
--- | ||
namespace: volsync-test-block | ||
resources: | ||
- ../base | ||
- deploy.yaml | ||
patches: | ||
# Customize for internal ceph rbd storage. | ||
- target: | ||
kind: PersistentVolumeClaim | ||
name: busybox-pvc | ||
patch: |- | ||
- op: replace | ||
path: /spec/storageClassName | ||
value: rook-ceph-block | ||
- op: replace | ||
path: /spec/accessModes | ||
value: | ||
- ReadWriteOnce | ||
- op: replace | ||
path: /spec/volumeMode | ||
value: Block |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# SPDX-FileCopyrightText: The RamenDR authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
--- | ||
namespace: volsync-test-block | ||
resources: | ||
- ../base | ||
patches: | ||
# Customize for internal ceph rbd storage. | ||
- target: | ||
kind: PersistentVolumeClaim | ||
name: volsync-pvc | ||
patch: |- | ||
- op: replace | ||
path: /spec/storageClassName | ||
value: rook-ceph-block | ||
- op: replace | ||
path: /spec/accessModes | ||
value: | ||
- ReadWriteOnce | ||
- op: replace | ||
path: /spec/volumeMode | ||
value: Block | ||
- target: | ||
kind: ReplicationDestination | ||
name: busybox-dst | ||
patch: |- | ||
- op: replace | ||
path: /spec/rsyncTLS/storageClassName | ||
value: rook-ceph-block | ||
- op: replace | ||
path: /spec/rsyncTLS/volumeSnapshotClassName | ||
value: csi-rbdplugin-snapclass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# SPDX-FileCopyrightText: The RamenDR authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
--- | ||
apiVersion: volsync.backube/v1alpha1 | ||
kind: ReplicationSource | ||
metadata: | ||
name: busybox-src | ||
spec: | ||
sourcePVC: busybox-pvc | ||
trigger: | ||
manual: replication-1 | ||
rsyncTLS: | ||
keySecret: volsync-rsync-tls-busybox-dst-block | ||
address: volsync-rsync-tls-dst-busybox-dst.volsync-test-block.svc.clusterset.local | ||
copyMethod: Snapshot | ||
volumeSnapshotClassName: csi-rbdplugin-snapclass | ||
moverSecurityContext: | ||
runAsUser: 10000 | ||
runAsGroup: 10000 | ||
fsGroup: 10000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# SPDX-FileCopyrightText: The RamenDR authors | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
--- | ||
apiVersion: v1 | ||
kind: Secret | ||
type: Opaque | ||
metadata: | ||
name: volsync-rsync-tls-busybox-dst-block | ||
data: | ||
psk.txt: $value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters