-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdockerfile
More file actions
42 lines (31 loc) · 1.05 KB
/
dockerfile
File metadata and controls
42 lines (31 loc) · 1.05 KB
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
31
32
33
34
35
36
37
38
39
40
41
42
# Dockerfile
FROM php:8.2.4-fpm
# Instalacja zależności
RUN apt-get update && apt-get install -y \
libpq-dev \
&& docker-php-ext-install pdo_pgsql
RUN apt-get update && \
apt-get install -y netcat && \
rm -rf /var/lib/apt/lists/*
RUN apt-get update && \
apt-get install -y postgresql-client && \
rm -rf /var/lib/apt/lists/*
COPY composer.json /var/www/html/
COPY composer.lock /var/www/html/
RUN apt-get update && \
apt-get install -y --no-install-recommends \
wget \
unzip && \
rm -rf /var/lib/apt/lists/* && \
wget https://getcomposer.org/installer -O composer-setup.php && \
php composer-setup.php --install-dir=/usr/local/bin --filename=composer && \
rm composer-setup.php
RUN composer install --no-interaction --no-scripts
COPY .env /var/www/html/.env
COPY nginx.conf /etc/nginx/nginx.conf
COPY docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh
RUN chmod +x /usr/local/bin/docker-entrypoint.sh
WORKDIR /var/www/html
ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]
CMD ["php-fpm"]
EXPOSE 8000