blob: e81a7b57c77fd36feba2f0c5b4a95ae0fa493894 [file] [log] [blame]
bravof7751aba2021-10-20 11:48:16 -03001# Copyright 2021 Whitestack, LLC
Eduardo Sousa3c761742019-02-05 16:19:31 +00002#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may
4# not use this file except in compliance with the License. You may obtain
5# a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations
13# under the License.
14#
15# For those usages not covered by the Apache License, Version 2.0 please
bravof7751aba2021-10-20 11:48:16 -030016# contact: fbravo@whitestack.com or glavado@whitestack.com
Eduardo Sousa3c761742019-02-05 16:19:31 +000017##
18
bravof7751aba2021-10-20 11:48:16 -030019FROM ubuntu:20.04
Eduardo Sousa09a1e972018-09-21 11:06:32 +010020
21EXPOSE 5000
22
23WORKDIR /keystone
24
25COPY scripts/start.sh /keystone/start.sh
26
bravof7751aba2021-10-20 11:48:16 -030027RUN DEBIAN_FRONTEND=noninteractive apt-get update && \
28 DEBIAN_FRONTEND=noninteractive apt-get upgrade -y && \
29 DEBIAN_FRONTEND=noninteractive apt-get autoremove -y && \
30 DEBIAN_FRONTEND=noninteractive apt-get install -y software-properties-common && \
31 add-apt-repository -y cloud-archive:victoria && \
32 DEBIAN_FRONTEND=noninteractive apt-get update && \
33 DEBIAN_FRONTEND=noninteractive apt-get dist-upgrade -y && \
34 DEBIAN_FRONTEND=noninteractive apt-get install -y \
35 apache2=2.4.* \
36 keystone=2:18.0.* \
37 libapache2-mod-wsgi-py3=4.6.* \
38 python3-pip=20.0.* \
39 build-essential=12.8* \
40 python3-dev=3.8.* \
41 libldap2-dev=2.4.* \
42 libsasl2-dev=2.1.* \
43 libssl-dev=1.1.* \
44 libffi-dev=3.3* \
45 libxml2-dev=2.9.* \
46 libxslt1-dev=1.1.* \
47 zlib1g-dev=1:1.2.* \
48 ldap-utils=2.4.* \
49 curl=7.68.* \
50 net-tools=1.60* \
51 mysql-client=8.0.* \
52 dnsutils=1:9.16.* && \
Eduardo Sousa09a1e972018-09-21 11:06:32 +010053 rm -rf /var/lib/apt/lists/* && \
54 chmod +x start.sh
55
sousaedu7f316e02021-11-16 23:16:09 +000056RUN pip3 install -U pip==21.3.1 && \
57 pip3 install python-ldap==3.2.0 ldappool==3.0.0 python-openstackclient==5.7.0
bravof7751aba2021-10-20 11:48:16 -030058
Eduardo Sousae8d792a2018-10-24 00:26:58 +010059# database
60ENV DB_HOST keystone-db
61ENV DB_PORT 3306
62ENV ROOT_DB_USER root
63ENV ROOT_DB_PASSWORD admin
Eduardo Sousae8d792a2018-10-24 00:26:58 +010064ENV KEYSTONE_DB_PASSWORD admin
Eduardo Sousac50ed8f2019-04-08 17:17:54 +010065# keystone
66ENV REGION_ID RegionOne
67ENV KEYSTONE_HOST keystone
68# admin user
69ENV ADMIN_USERNAME admin
Eduardo Sousae8d792a2018-10-24 00:26:58 +010070ENV ADMIN_PASSWORD admin
Eduardo Sousac50ed8f2019-04-08 17:17:54 +010071ENV ADMIN_PROJECT admin
72# nbi service user
73ENV SERVICE_USERNAME nbi
74ENV SERVICE_PASSWORD nbi
75ENV SERVICE_PROJECT service
David Garcia6fff9af2020-03-23 15:32:43 +010076# ldap
77# ENV LDAP_AUTHENTICATION_DOMAIN_NAME no default
78# ENV LDAP_URL ldap://localhost
sousaedu126a4432020-09-23 13:28:25 +010079# ENV LDAP_BIND_USER no default
David Garcia6fff9af2020-03-23 15:32:43 +010080# ENV LDAP_BIND_PASSWORD no default
sousaedubb631be2020-10-20 01:15:37 +010081# ENV LDAP_CHASE_REFERRALS no default
82# ENV LDAP_PAGE_SIZE 0
David Garcia6fff9af2020-03-23 15:32:43 +010083# ENV LDAP_USER_TREE_DN no default
84# ENV LDAP_USER_OBJECTCLASS inetOrgPerson
85# ENV LDAP_USER_ID_ATTRIBUTE cn
86# ENV LDAP_USER_NAME_ATTRIBUTE sn
87# ENV LDAP_USER_PASS_ATTRIBUTE userPassword
88# ENV LDAP_USER_FILTER no default
89# ENV LDAP_USER_ENABLED_ATTRIBUTE enabled
90# ENV LDAP_USER_ENABLED_MASK 0
91# ENV LDAP_USER_ENABLED_DEFAULT true
92# ENV LDAP_USER_ENABLED_INVERT false
sousaedubb631be2020-10-20 01:15:37 +010093# ENV LDAP_GROUP_OBJECTCLASS groupOfNames
94# ENV LDAP_GROUP_TREE_DN no default
David Garcia6fff9af2020-03-23 15:32:43 +010095# ENV LDAP_USE_STARTTLS false
96# ENV LDAP_TLS_CACERT_BASE64 no default
97# ENV LDAP_TLS_REQ_CERT demand
Eduardo Sousa09a1e972018-09-21 11:06:32 +010098
bravof7751aba2021-10-20 11:48:16 -030099ENTRYPOINT ["./start.sh"]