aboutsummaryrefslogtreecommitdiff
path: root/docker
diff options
context:
space:
mode:
authorAndrey Shestakov <ashestakov@mirantis.com>2015-12-23 23:17:47 +0200
committerAndrey Shestakov <ashestakov@mirantis.com>2015-12-29 12:49:03 +0000
commit1a368c91349466167c818cfc2f56ebb5ace86872 (patch)
tree46df53da1dd58a1610dab13b4df095aadb0f4d57 /docker
parenta5a5b3fd61884773a4046526be255ba24bfdc9de (diff)
downloadkolla-1a368c91349466167c818cfc2f56ebb5ace86872.tar.gz
kolla-1a368c91349466167c818cfc2f56ebb5ace86872.zip
Add RadosGW container
Implements blueprint radosgw-container Change-Id: Idc88a67a0979be626d3eaa9b2b9a527010aa2006
Diffstat (limited to 'docker')
-rw-r--r--docker/ceph/ceph-base/Dockerfile.j22
-rw-r--r--docker/ceph/ceph-mon/Dockerfile.j22
-rw-r--r--docker/ceph/ceph-mon/extend_start.sh3
-rw-r--r--docker/ceph/ceph-mon/fetch_ceph_keys.py3
-rw-r--r--docker/ceph/ceph-osd/Dockerfile.j22
-rw-r--r--docker/ceph/ceph-rgw/Dockerfile.j24
6 files changed, 15 insertions, 1 deletions
diff --git a/docker/ceph/ceph-base/Dockerfile.j2 b/docker/ceph/ceph-base/Dockerfile.j2
index 32288f7dd..c51cad819 100644
--- a/docker/ceph/ceph-base/Dockerfile.j2
+++ b/docker/ceph/ceph-base/Dockerfile.j2
@@ -5,6 +5,7 @@ MAINTAINER {{ maintainer }}
RUN yum -y install \
ceph \
+ ceph-radosgw \
parted \
hdparm \
&& yum clean all
@@ -13,6 +14,7 @@ RUN yum -y install \
RUN apt-get install -y --no-install-recommends \
ceph \
+ radosgw \
parted \
hdparm \
&& apt-get clean
diff --git a/docker/ceph/ceph-mon/Dockerfile.j2 b/docker/ceph/ceph-mon/Dockerfile.j2
index 6fdaff6ee..38c8d26f6 100644
--- a/docker/ceph/ceph-mon/Dockerfile.j2
+++ b/docker/ceph/ceph-mon/Dockerfile.j2
@@ -5,3 +5,5 @@ COPY fetch_ceph_keys.py /usr/bin/
COPY extend_start.sh /usr/local/bin/kolla_extend_start
RUN chmod 755 /usr/local/bin/kolla_extend_start /usr/bin/fetch_ceph_keys.py
+
+{{ include_footer }}
diff --git a/docker/ceph/ceph-mon/extend_start.sh b/docker/ceph/ceph-mon/extend_start.sh
index dce6749b3..3b8246e37 100644
--- a/docker/ceph/ceph-mon/extend_start.sh
+++ b/docker/ceph/ceph-mon/extend_start.sh
@@ -3,6 +3,7 @@
# Setup common paths
KEYRING_ADMIN="/etc/ceph/ceph.client.admin.keyring"
KEYRING_MON="/etc/ceph/ceph.client.mon.keyring"
+KEYRING_RGW="/etc/ceph/ceph.client.radosgw.keyring"
MONMAP="/etc/ceph/ceph.monmap"
MON_DIR="/var/lib/ceph/mon/ceph-$(hostname)"
@@ -15,7 +16,9 @@ if [[ "${!KOLLA_BOOTSTRAP[@]}" ]]; then
# Generating initial keyrings and monmap
ceph-authtool --create-keyring "${KEYRING_MON}" --gen-key -n mon. --cap mon 'allow *'
ceph-authtool --create-keyring "${KEYRING_ADMIN}" --gen-key -n client.admin --set-uid=0 --cap mon 'allow *' --cap osd 'allow *' --cap mds 'allow'
+ ceph-authtool --create-keyring "${KEYRING_RGW}" --gen-key -n client.radosgw.gateway --set-uid=0 --cap osd 'allow rwx' --cap mon 'allow rwx'
ceph-authtool "${KEYRING_MON}" --import-keyring "${KEYRING_ADMIN}"
+ ceph-authtool "${KEYRING_MON}" --import-keyring "${KEYRING_RGW}"
monmaptool --create --add "$(hostname)" "${MON_IP}" --fsid "${FSID}" "${MONMAP}"
echo "Sleeping until keys are fetched"
diff --git a/docker/ceph/ceph-mon/fetch_ceph_keys.py b/docker/ceph/ceph-mon/fetch_ceph_keys.py
index ab2be9c16..3303bdf5c 100644
--- a/docker/ceph/ceph-mon/fetch_ceph_keys.py
+++ b/docker/ceph/ceph-mon/fetch_ceph_keys.py
@@ -57,9 +57,10 @@ def read_file(filename):
def main():
admin_keyring = 'ceph.client.admin.keyring'
mon_keyring = 'ceph.client.mon.keyring'
+ rgw_keyring = 'ceph.client.radosgw.keyring'
monmap = 'ceph.monmap'
- files = [admin_keyring, mon_keyring, monmap]
+ files = [admin_keyring, mon_keyring, rgw_keyring, monmap]
json_exit({filename: read_file(filename) for filename in files})
diff --git a/docker/ceph/ceph-osd/Dockerfile.j2 b/docker/ceph/ceph-osd/Dockerfile.j2
index 9026907de..03e4dceda 100644
--- a/docker/ceph/ceph-osd/Dockerfile.j2
+++ b/docker/ceph/ceph-osd/Dockerfile.j2
@@ -3,3 +3,5 @@ MAINTAINER {{ maintainer }}
COPY extend_start.sh /usr/local/bin/kolla_extend_start
RUN chmod 755 /usr/local/bin/kolla_extend_start
+
+{{ include_footer }}
diff --git a/docker/ceph/ceph-rgw/Dockerfile.j2 b/docker/ceph/ceph-rgw/Dockerfile.j2
new file mode 100644
index 000000000..cf6000906
--- /dev/null
+++ b/docker/ceph/ceph-rgw/Dockerfile.j2
@@ -0,0 +1,4 @@
+FROM {{ namespace }}/{{ image_prefix }}ceph-base:{{ tag }}
+MAINTAINER {{ maintainer }}
+
+{{ include_footer }}