diff --git a/docker/Dockerfile b/docker/Dockerfile new file mode 100644 index 0000000..7568ec6 --- /dev/null +++ b/docker/Dockerfile @@ -0,0 +1,22 @@ +# Use the official Debian image as a base +FROM debian:latest + +# Set environment variables +# ENV DEBIAN_FRONTEND=noninteractive + +# Update the package list and install Apache2 and MariaDB +RUN apt-get update && \ + apt-get install -y apache2 && \ + apt-get clean && \ + rm -rf /var/lib/apt/lists/* + + +# Copy your website files to the Apache document root (optional) +COPY ./install/apache2-sites/coloradio.conf /etc/conf/apache2/sites-enabled/ + +# Expose ports for Apache and MariaDB +EXPOSE 80 + +# Start both Apache and MariaDB +CMD service apache2 start && \ + tail -f /var/log/apache2/access.log diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml new file mode 100644 index 0000000..2e12170 --- /dev/null +++ b/docker/docker-compose.yml @@ -0,0 +1,23 @@ +services: + #web: + # build: + # context: .. + # dockerfile: ./docker/Dockerfile + # ports: + # - "80:80" + # #volumes: + # #- ./your-website-files:/var/www/html/ + # #- ./httpd.conf:/etc/apache2/sites-available/000-default.conf + + db: + image: mariadb:10 + environment: + MYSQL_ROOT_PASSWORD: yourpassword + #MYSQL_DATABASE: yourdatabase + MYSQL_USER: test + MYSQL_PASSWORD: test + ports: + - "3306:3306" + volumes: + - ../install/init.sql:/docker-entrypoint-initdb.d/01-init.sql + - ../install/create.sql:/docker-entrypoint-initdb.d/02-create.sql