blob: 445111699eff5f749748c18a021565dcd83752f1 [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
bravof7751aba2021-10-20 11:48:16 -030056RUN pip3 install -U pip==21.3.1 && pip3 install python-ldap==3.2.0 ldappool==3.0.0
57
Eduardo Sousae8d792a2018-10-24 00:26:58 +010058# database
59ENV DB_HOST keystone-db
60ENV DB_PORT 3306
61ENV ROOT_DB_USER root
62ENV ROOT_DB_PASSWORD admin
Eduardo Sousae8d792a2018-10-24 00:26:58 +010063ENV KEYSTONE_DB_PASSWORD admin
Eduardo Sousac50ed8f2019-04-08 17:17:54 +010064# keystone
65ENV REGION_ID RegionOne
66ENV KEYSTONE_HOST keystone
67# admin user
68ENV ADMIN_USERNAME admin
Eduardo Sousae8d792a2018-10-24 00:26:58 +010069ENV ADMIN_PASSWORD admin
Eduardo Sousac50ed8f2019-04-08 17:17:54 +010070ENV ADMIN_PROJECT admin
71# nbi service user
72ENV SERVICE_USERNAME nbi
73ENV SERVICE_PASSWORD nbi
74ENV SERVICE_PROJECT service
David Garcia6fff9af2020-03-23 15:32:43 +010075# ldap
76# ENV LDAP_AUTHENTICATION_DOMAIN_NAME no default
77# ENV LDAP_URL ldap://localhost
sousaedu126a4432020-09-23 13:28:25 +010078# ENV LDAP_BIND_USER no default
David Garcia6fff9af2020-03-23 15:32:43 +010079# ENV LDAP_BIND_PASSWORD no default
sousaedubb631be2020-10-20 01:15:37 +010080# ENV LDAP_CHASE_REFERRALS no default
81# ENV LDAP_PAGE_SIZE 0
David Garcia6fff9af2020-03-23 15:32:43 +010082# ENV LDAP_USER_TREE_DN no default
83# ENV LDAP_USER_OBJECTCLASS inetOrgPerson
84# ENV LDAP_USER_ID_ATTRIBUTE cn
85# ENV LDAP_USER_NAME_ATTRIBUTE sn
86# ENV LDAP_USER_PASS_ATTRIBUTE userPassword
87# ENV LDAP_USER_FILTER no default
88# ENV LDAP_USER_ENABLED_ATTRIBUTE enabled
89# ENV LDAP_USER_ENABLED_MASK 0
90# ENV LDAP_USER_ENABLED_DEFAULT true
91# ENV LDAP_USER_ENABLED_INVERT false
sousaedubb631be2020-10-20 01:15:37 +010092# ENV LDAP_GROUP_OBJECTCLASS groupOfNames
93# ENV LDAP_GROUP_TREE_DN no default
David Garcia6fff9af2020-03-23 15:32:43 +010094# ENV LDAP_USE_STARTTLS false
95# ENV LDAP_TLS_CACERT_BASE64 no default
96# ENV LDAP_TLS_REQ_CERT demand
Eduardo Sousa09a1e972018-09-21 11:06:32 +010097
bravof7751aba2021-10-20 11:48:16 -030098ENTRYPOINT ["./start.sh"]