From d652ea73802ca2970174a098ea48a838e9778db5 Mon Sep 17 00:00:00 2001 From: Matthew McKinnon Date: Sun, 7 Aug 2022 13:37:05 +1000 Subject: [PATCH] Added Dockerfile and gitlab-ci.yml --- .gitlab-ci.yml | 16 ++++++++++++++++ Dockerfile | 13 +++++++++++++ docker-compose.yml | 9 +++++++++ 3 files changed, 38 insertions(+) create mode 100644 .gitlab-ci.yml create mode 100644 Dockerfile create mode 100644 docker-compose.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..d79a855 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,16 @@ +stages: + - build-eleventy +build-eleventy: + stage: build-eleventy + image: node:latest + cache: + paths: + - node_modules/ + script: + - npm install + - npm run build + artifacts: + paths: + - _site/ + only: + - master diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..3dbf397 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,13 @@ +FROM php:8.1-apache + +MAINTAINER Matthew McKinnon + +ENV DEBIAN_FRONTEND noninteractive + +RUN apt-get update +RUN apt-get clean && rm -rf /var/lib/apt/lists/* + +COPY --from=composer:2 /usr/bin/composer /usr/local/bin/composer +COPY _site/ /var/www/html + +WORKDIR / diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..a585dac --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,9 @@ +--- +version: '3' +services: + comprofix: + build: + context: . + container_name: comprofix + ports: + - 8080:80