Added Dockerfile for nginx-ldap-auth-daemon.py.
This commit is contained in:
parent
cdc0abff91
commit
1262eaf8a3
|
|
@ -0,0 +1,16 @@
|
||||||
|
FROM python:2-alpine
|
||||||
|
|
||||||
|
COPY nginx-ldap-auth-daemon.py /usr/src/app/
|
||||||
|
|
||||||
|
WORKDIR /usr/src/app/
|
||||||
|
|
||||||
|
# Install required software
|
||||||
|
RUN \
|
||||||
|
apk --no-cache add openldap-dev && \
|
||||||
|
apk --no-cache add --virtual build-dependencies build-base && \
|
||||||
|
pip install python-ldap && \
|
||||||
|
apk del build-dependencies
|
||||||
|
|
||||||
|
EXPOSE 8888
|
||||||
|
|
||||||
|
CMD ["python", "/usr/src/app/nginx-ldap-auth-daemon.py", "--host", "0.0.0.0", "--port", "8888"]
|
||||||
|
|
@ -38,6 +38,14 @@ To install and configure the reference implementation, perform the following ste
|
||||||
1. Copy the following files from your repository clone to the indicated hosts:
|
1. Copy the following files from your repository clone to the indicated hosts:
|
||||||
- **nginx-ldap-auth.conf** – NGINX Plus configuration file, which contains the minimal set of directives for testing the reference implementation. Install on the NGINX Plus host (in the **/etc/nginx/conf.d** directory if using the conventional configuration scheme). To avoid configuration conflicts, remember to move or rename any default configuration files installed with NGINX Plus.
|
- **nginx-ldap-auth.conf** – NGINX Plus configuration file, which contains the minimal set of directives for testing the reference implementation. Install on the NGINX Plus host (in the **/etc/nginx/conf.d** directory if using the conventional configuration scheme). To avoid configuration conflicts, remember to move or rename any default configuration files installed with NGINX Plus.
|
||||||
- **nginx-ldap-auth-daemon.py** – Python code for the ldap-auth daemon. Install on the host of your choice.
|
- **nginx-ldap-auth-daemon.py** – Python code for the ldap-auth daemon. Install on the host of your choice.
|
||||||
|
|
||||||
|
Alternatively, use provided Dockerfile to build Docker image:
|
||||||
|
|
||||||
|
```
|
||||||
|
docker build -t nginx-ldap-auth-daemon .
|
||||||
|
docker run nginx-ldap-auth-daemon
|
||||||
|
```
|
||||||
|
|
||||||
- **nginx-ldap-auth-daemon-ctl.sh** – Sample shell script for starting and stopping the daemon. Install on the same host as the ldap-auth daemon.
|
- **nginx-ldap-auth-daemon-ctl.sh** – Sample shell script for starting and stopping the daemon. Install on the same host as the ldap-auth daemon.
|
||||||
- **backend-sample-app.py** – Python code for the daemon that during testing stands in for a real back-end application server. Install on the host of your choice.
|
- **backend-sample-app.py** – Python code for the daemon that during testing stands in for a real back-end application server. Install on the host of your choice.
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue