-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
FROM php:8.3-fpm | ||
|
||
ARG NODE_MAJOR=20 | ||
|
||
RUN apt-get update \ | ||
&& apt-get install -y \ | ||
git \ | ||
espeak-ng \ | ||
# Install node | ||
ca-certificates \ | ||
curl \ | ||
gnupg \ | ||
# see https://github.com/nodesource/distributions | ||
&& mkdir -p /etc/apt/keyrings \ | ||
&& curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg \ | ||
&& echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ | ||
&& apt-get update \ | ||
&& apt-get install nodejs -y \ | ||
&& node --version \ | ||
&& npm --version \ | ||
# Clean package cache | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# Install PHP extensions and Composer | ||
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/ | ||
RUN chmod uga+x /usr/local/bin/install-php-extensions && sync \ | ||
&& install-php-extensions \ | ||
gd \ | ||
xdebug \ | ||
zip \ | ||
@composer \ | ||
&& rm /usr/local/bin/install-php-extensions | ||
|
||
COPY xdebug.ini /usr/local/etc/php/conf.d/ | ||
|
||
RUN echo "alias jigsaw=./vendor/bin/jigsaw" >> /etc/bash.bashrc && \ | ||
echo "alias compile='./vendor/bin/jigsaw build'" >> /etc/bash.bashrc && \ | ||
/bin/bash -c "source /etc/bash.bashrc" | ||
|
||
WORKDIR /var/www/html | ||
|
||
COPY entrypoint.sh /var/www/scripts/ | ||
ENTRYPOINT [ "bash", "/var/www/scripts/entrypoint.sh" ] |