Created
February 14, 2022 17:43
-
-
Save cbodley/acaa9af4a55d35ddddedc1dccdbb3e5f to your computer and use it in GitHub Desktop.
setup_multi.sh to deploy two vstart clusters and configure for multisite
This file contains hidden or 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
#!/bin/bash -ex | |
RGW_ACCESS=DiPt4V7WWvy2njL1z6aC | |
RGW_SECRET=xSZUdYky0bTctAdCEEW8ikhfBVKsBV5LFYL82vvh | |
HOSTNAME=localhost | |
export CEPH_NUM_OSD=1 | |
export CEPH_NUM_MON=1 | |
export CEPH_NUM_MDS=0 | |
export CEPH_NUM_MGR=0 | |
CEPH_SRC=${CEPH_SRC:-../src} | |
CEPH_BIN=${CEPH_BIN:-bin} | |
${CEPH_SRC}/mstart.sh c1 -n -d | |
${CEPH_SRC}/mrun c1 radosgw-admin realm create --rgw-realm dev --default | |
${CEPH_SRC}/mrun c1 radosgw-admin zonegroup create --rgw-zonegroup na --endpoints http://${HOSTNAME}:8000 --master --default | |
${CEPH_SRC}/mrun c1 radosgw-admin zone create --rgw-zone na-1 --rgw-zonegroup na --endpoints http://${HOSTNAME}:8000 --access-key $RGW_ACCESS --secret $RGW_SECRET --master --default | |
${CEPH_SRC}/mrun c1 radosgw-admin period update --commit | |
${CEPH_SRC}/mrun c1 radosgw-admin user create --uid realm.admin --display-name 'Realm Admin' --access-key $RGW_ACCESS --secret $RGW_SECRET --system | |
${CEPH_SRC}/mrun c1 radosgw-admin user create \ | |
--uid testid \ | |
--access-key 0555b35654ad1656d804 \ | |
--secret h7GhxuBLTrlhVUyxSPUKUV8r/2EI4ngqJxD7iBdBYLhwluN30JaT3Q== \ | |
--display-name 'M. Tester' \ | |
--email [email protected] | |
${CEPH_SRC}/mrun c1 radosgw-admin user create \ | |
--uid 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef \ | |
--access-key ABCDEFGHIJKLMNOPQRST \ | |
--secret abcdefghijklmnopqrstuvwxyzabcdefghijklmn \ | |
--display-name youruseridhere \ | |
--email [email protected] | |
${CEPH_SRC}/mrun c1 radosgw-admin user create \ | |
--uid 56789abcdef0123456789abcdef0123456789abcdef0123456789abcdef01234 \ | |
--access-key NOPQRSTUVWXYZABCDEFG \ | |
--secret nopqrstuvwxyzabcdefghijklmnabcdefghijklm \ | |
--display-name john.doe \ | |
--email [email protected] | |
${CEPH_SRC}/mrun c1 radosgw-admin user create \ | |
--tenant storage \ | |
--uid 9876543210abcdef0123456789abcdef0123456789abcdef0123456789abcdef \ | |
--access-key HIJKLMNOPQRSTUVWXYZA \ | |
--secret opqrstuvwxyzabcdefghijklmnopqrstuvwxyzab \ | |
--display-name tenanteduser \ | |
--email [email protected] | |
${CEPH_SRC}/mrun c1 radosgw-admin user create --subuser=test:tester --display-name=Tester-Subuser --key-type=swift --secret=testing --access=full | |
${CEPH_SRC}/mrgw.sh c1 8000 0 --debug-rgw 20 --debug-ms 1 | |
${CEPH_SRC}/mstart.sh c2 -n -d | |
${CEPH_SRC}/mrun c2 radosgw-admin realm pull --rgw-realm dev --url http://${HOSTNAME}:8000 --access-key $RGW_ACCESS --secret $RGW_SECRET --default | |
${CEPH_SRC}/mrun c2 radosgw-admin zone create --rgw-zone na-2 --rgw-zonegroup na --endpoints http://${HOSTNAME}:8001 --access-key $RGW_ACCESS --secret $RGW_SECRET --default | |
${CEPH_SRC}/mrun c2 radosgw-admin period update --commit | |
${CEPH_SRC}/mrgw.sh c2 8001 0 --debug-rgw 20 --debug-ms 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment