Resources attached to the Road To DevOps tutorial
https://blog.noobtoroot.xyz/road-to-devops/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
719 B
30 lines
719 B
FROM debian:bullseye |
|
|
|
LABEL maintainer "me@sii.fr" |
|
|
|
# Debian en mode non interactif |
|
ENV DEBIAN_FRONTEND noninteractive |
|
|
|
# On installe Apache et le client Mysql |
|
# et on nettoie le cache apt pour diminuer la taille de l'image |
|
RUN apt update \ |
|
&& apt install -y apache2 mariadb-client \ |
|
&& rm -rf /var/lib/apt/lists/* |
|
|
|
# On copie nos scripts |
|
COPY index.sh /usr/lib/cgi-bin/index.sh |
|
COPY docker.sql /tmp/docker.sql |
|
COPY start.sh /start.sh |
|
|
|
# On rend les scripts exécutables |
|
RUN chmod +x /start.sh |
|
RUN chmod +x /usr/lib/cgi-bin/index.sh |
|
|
|
# On active le module Apache CGI |
|
RUN a2enmod cgi |
|
|
|
# On expose le port 80 |
|
EXPOSE 80 |
|
|
|
# On indique le script qui doit être lancé au démarrage du conteneur |
|
ENTRYPOINT ["/start.sh"]
|
|
|