-
Notifications
You must be signed in to change notification settings - Fork 140
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
2 changed files
with
48 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,35 @@ | ||
FROM php:apache | ||
|
||
ENV APACHE_RUN_USER=www-data | ||
|
||
ENV APACHE_RUN_GROUP=www-data | ||
|
||
ENV APACHE_RUN_DIR=/var/run/apache2 | ||
|
||
ENV APACHE_LOG_DIR=/var/log/apache2 | ||
|
||
ENV APACHE_LOCK_DIR=/var/lock/apache2 | ||
|
||
ENV APACHE_PID_FILE=/var/run/apache2/apache2.pid | ||
|
||
RUN apt update && apt install -y git zip unzip libzip-dev libicu-dev nodejs npm | ||
|
||
RUN git clone https://github.com/omeka/omeka-s . | ||
|
||
RUN npm install | ||
|
||
RUN docker-php-ext-install pdo_mysql intl | ||
|
||
RUN npx gulp init | ||
|
||
RUN a2enmod rewrite | ||
|
||
RUN chown -R www-data:www-data /var/www/html/ | ||
|
||
COPY docker-entrypoint.sh . | ||
|
||
VOLUME /var/www/html/files | ||
|
||
CMD ["apache2", "-D", "FOREGROUND"] | ||
|
||
ENTRYPOINT ["./docker-entrypoint.sh"] |
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,13 @@ | ||
#!/bin/bash | ||
|
||
cp config/database.ini.dist config/database.ini | ||
|
||
sed -i -e 's/user = ""/user = "'$MYSQL_USER'"/g' config/database.ini | ||
|
||
sed -i -e 's/password = ""/password = "'$MYSQL_PASSWORD'"/g' config/database.ini | ||
|
||
sed -i -e 's/dbname = ""/dbname = "'$MYSQL_DATABASE'"/g' config/database.ini | ||
|
||
sed -i -e 's/host = ""/host = "'$MYSQL_HOST'"/g' config/database.ini | ||
|
||
exec "$@" |