dockerizazioa
This commit is contained in:
parent
645edec125
commit
4f0097ac1b
14
Dockerfile
14
Dockerfile
@ -1,9 +1,8 @@
|
|||||||
FROM python:3-alpine
|
FROM python:3-alpine
|
||||||
|
|
||||||
ARG USER_
|
ARG USER_=admin
|
||||||
ARG UID_
|
ARG UID_=1000
|
||||||
ENV USER_=admin
|
|
||||||
ENV UID_=1000
|
|
||||||
RUN apk add --no-cache --upgrade bash
|
RUN apk add --no-cache --upgrade bash
|
||||||
|
|
||||||
ADD --chown=$UID_:$UID_ . /www
|
ADD --chown=$UID_:$UID_ . /www
|
||||||
@ -19,8 +18,7 @@ RUN set -e; \
|
|||||||
pip install -r requirements.txt; \
|
pip install -r requirements.txt; \
|
||||||
apk del .build-deps;
|
apk del .build-deps;
|
||||||
|
|
||||||
#RUN adduser -S -D $USER -u $UID_
|
RUN adduser -S -D $USER_ -u $UID_
|
||||||
#USER $USER
|
USER $USER_
|
||||||
|
|
||||||
ENTRYPOINT ["./start.sh", "$UID_"]
|
ENTRYPOINT ["./start.sh"]
|
||||||
#CMD ["$UID_"]
|
|
||||||
|
@ -52,7 +52,7 @@ Konfiguraketa fitxategia sortu:
|
|||||||
|
|
||||||
edo
|
edo
|
||||||
|
|
||||||
docker build -t aitzol/ldap-webui:latest . --build-arg UID_=$UID
|
docker build -t aitzol/ldap-webui:latest . --build-arg UID_=$UID --build-arg USER_=$USER
|
||||||
|
|
||||||
#### Edukiontzia sortu
|
#### Edukiontzia sortu
|
||||||
|
|
||||||
|
7
start.sh
7
start.sh
@ -11,8 +11,11 @@ fi
|
|||||||
if [[ $# -gt 0 ]]; then
|
if [[ $# -gt 0 ]]; then
|
||||||
UID_=$1
|
UID_=$1
|
||||||
echo $UID_
|
echo $UID_
|
||||||
export LDAP_ADMIN_PASSWORD=admin
|
else
|
||||||
export LDAP_READONLY_PASSWORD=readonly
|
UID_=$UID
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
export LDAP_ADMIN_PASSWORD=admin
|
||||||
|
export LDAP_READONLY_PASSWORD=readonly
|
||||||
|
|
||||||
uwsgi --http :9090 --enable-threads --uid $UID_ --wsgi-file app.py
|
uwsgi --http :9090 --enable-threads --uid $UID_ --wsgi-file app.py
|
||||||
|
Loading…
Reference in New Issue
Block a user