From 6b24a8d7486145e5752204d628df31302caedb8a Mon Sep 17 00:00:00 2001 From: thisfro Date: Wed, 5 May 2021 11:50:04 +0200 Subject: [PATCH] add dockerfile for ci --- Dockerfile | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..7baea6d --- /dev/null +++ b/Dockerfile @@ -0,0 +1,22 @@ +FROM php:8.0.5-fpm-buster + +RUN apt-get update && apt-get -y install wget git npm curl + +RUN apt-get install -y libpq-dev \ + && docker-php-ext-configure pgsql -with-pgsql=/usr/local/pgsql \ + && docker-php-ext-install pdo pdo_pgsql pgsql + +RUN php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \ + php -r "if (hash_file('sha384', 'composer-setup.php') === '756890a4488ce9024fc62c56153228907f1545c228516cbf63f885e036d37e9a59d27d63f46af1d4d07ee0f76181c7d3') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" && \ + php composer-setup.php && \ + php -r "unlink('composer-setup.php');" + +RUN npm install --global yarn + +RUN php composer.phar update && yarn +RUN yarn build +RUN wget https://get.symfony.com/cli/installer -O - | bash && \ + +COPY .env .env + +CMD /root/.symfony/bin/symfony console doctrine:migrations:migrate && /root/.symfony/bin/symfony serve --port=9999 --no-tls