MAPG-2 Init project MapGuesser
* add composer.json and basic environment * add basic classes * add basic map with JS and CSS (with demo functionality) * add files for docker-compose * add launch.json for Docker debug * add README
This commit is contained in:
commit
a61d2951d7
16 files changed
+692
No files matched your search
@@ -0,0 +1,31 @@
|
||||
FROM ubuntu:focal
|
||||
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
|
||||
# Install Apache, PHP and further necessary packages
|
||||
RUN apt update
|
||||
RUN apt install -y curl git apache2 \
|
||||
php-apcu php-xdebug php7.4-cli php7.4-fpm php7.4-mbstring php7.4-mysql php7.4-zip
|
||||
|
||||
# Configure tzdata
|
||||
#RUN ln -fs /usr/share/zoneinfo/Europe/Budapest /etc/localtime
|
||||
#RUN dpkg-reconfigure --frontend noninteractive tzdata
|
||||
|
||||
# Configure Apache with PHP
|
||||
RUN mkdir -p /run/php
|
||||
RUN a2enmod proxy_fcgi rewrite
|
||||
RUN a2enconf php7.4-fpm
|
||||
COPY configs/apache.conf /etc/apache2/sites-available/000-default.conf
|
||||
RUN echo "xdebug.remote_enable = 1" >> /etc/php/7.4/mods-available/xdebug.ini
|
||||
RUN echo "xdebug.remote_autostart = 1" >> /etc/php/7.4/mods-available/xdebug.ini
|
||||
RUN echo "xdebug.remote_connect_back = 1" >> /etc/php/7.4/mods-available/xdebug.ini
|
||||
|
||||
# Install Composer
|
||||
COPY scripts/install-composer.sh install-composer.sh
|
||||
RUN ./install-composer.sh
|
||||
|
||||
EXPOSE 80
|
||||
VOLUME /var/www/mapguesser
|
||||
WORKDIR /var/www/mapguesser
|
||||
|
||||
ENTRYPOINT /usr/sbin/php-fpm7.4 -F & /usr/sbin/apache2ctl -DFOREGROUND
|
||||
@@ -0,0 +1,15 @@
|
||||
<VirtualHost *:80>
|
||||
ServerName mapguesser-dev.ch
|
||||
|
||||
ServerAdmin webmaster@localhost
|
||||
DocumentRoot /var/www/mapguesser/public
|
||||
|
||||
ErrorLog ${APACHE_LOG_DIR}/error.log
|
||||
CustomLog ${APACHE_LOG_DIR}/access.log combined
|
||||
</VirtualHost>
|
||||
|
||||
<Directory /var/www/mapguesser/public>
|
||||
Options FollowSymLinks
|
||||
AllowOverride All
|
||||
Require all granted
|
||||
</Directory>
|
||||
Executable
+17
@@ -0,0 +1,17 @@
|
||||
#!/bin/sh
|
||||
|
||||
EXPECTED_CHECKSUM="$(curl -s https://composer.github.io/installer.sig)"
|
||||
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
|
||||
ACTUAL_CHECKSUM="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
|
||||
|
||||
if [ "$EXPECTED_CHECKSUM" != "$ACTUAL_CHECKSUM" ]
|
||||
then
|
||||
>&2 echo 'ERROR: Invalid installer checksum'
|
||||
rm composer-setup.php
|
||||
exit 1
|
||||
fi
|
||||
|
||||
php composer-setup.php --install-dir=/usr/local/bin --filename=composer
|
||||
RESULT=$?
|
||||
rm composer-setup.php
|
||||
exit $RESULT
|
||||
Reference in new issue
Block a user