-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.Dockerfile
30 lines (21 loc) · 956 Bytes
/
build.Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
FROM ubuntu:22.04
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update -y
RUN apt-get upgrade -y
RUN apt install lsb-release ca-certificates apt-transport-https software-properties-common -y
RUN add-apt-repository ppa:ondrej/php
RUN apt-get install -y curl zip unzip php8.2-fpm php8.2-cli php8.2-mysql php8.2-gd php8.2-curl php8.2-soap php8.2-mbstring php8.2-xml nginx
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash
RUN apt-get update -y
RUN apt-get install -y nodejs git
COPY ./config/nginx.conf /etc/nginx/
COPY ./config/default.conf /etc/nginx/conf.d/
COPY ./config/php/php.ini /etc/php/8.2/fpm/
COPY ./config/php/www.conf /etc/php/8.2/fpm/pool.d/
RUN mkdir /run/php/
COPY ./src/ /var/www/html/
WORKDIR /var/www/html/
RUN composer install
RUN chown -R www-data:www-data /var/www/html
CMD php-fpm8.2 && nginx -g "daemon off;"