hpc-cloud/roles/keystone/files/Dockerfile

24 lines
759 B
Docker
Raw Normal View History

# Build keystone. It needs to be run with
# --add-host=mariadb:<ip mariadb listens tp>
# Wen starting with an initialized db,
# run keystone-manage db_sync from this docker first:
# $ docker run hpc/keystone --add-host=mariadb:<ip mariadb> "keystone-manage db_sync"
2017-05-10 11:21:17 +02:00
FROM ubuntu:zesty
2017-05-10 11:21:17 +02:00
RUN apt-get update
2017-05-10 11:21:17 +02:00
RUN apt-get install --yes keystone
# configure keystone to connect to mariadb host.
2017-05-10 11:21:17 +02:00
RUN sed -i "s|database]|database]\nconnection = mysql://keystone:keystone@mariadb/keystone|g" /etc/keystone/keystone.conf
# set admin token TODO: make this a secret
RUN sed -i 's/#admin_token = ADMIN/admin_token = SuperSecreteKeystoneToken/g' /etc/keystone/keystone.conf
RUN mkdir /etc/keystone/fernet-keys
#RUN keystone-manage db_sync
2017-05-10 11:21:17 +02:00
CMD apachectl -DFOREGROUND