mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Docker: Use working directory instead of hardcoded dist version
- By using the current (.) working directory, we can get the latest changes in the Docker image. If the building of Docker images is automated, it will automatically pick up the checked out version. - Rearrange some Docker layers things that don't invalidate that much.
This commit is contained in:
parent
ee2fba415a
commit
a3e1821ca0
4
.dockerignore
Normal file
4
.dockerignore
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
# Ignore composer specific files and vendor folder
|
||||||
|
composer.phar
|
||||||
|
composer.lock
|
||||||
|
vendor
|
5
.gitignore
vendored
5
.gitignore
vendored
@ -1,8 +1,11 @@
|
|||||||
/node_modules
|
/node_modules
|
||||||
/public/storage
|
/public/storage
|
||||||
/vendor
|
|
||||||
Homestead.json
|
Homestead.json
|
||||||
Homestead.yaml
|
Homestead.yaml
|
||||||
.env
|
.env
|
||||||
public/google*.html
|
public/google*.html
|
||||||
report.html
|
report.html
|
||||||
|
|
||||||
|
### Composer ###
|
||||||
|
composer.phar
|
||||||
|
/vendor/
|
||||||
|
20
Dockerfile
20
Dockerfile
@ -23,18 +23,26 @@ RUN docker-php-ext-install -j$(nproc) curl gd intl json mcrypt readline tidy zip
|
|||||||
# Generate locales supported by firefly
|
# Generate locales supported by firefly
|
||||||
RUN echo "en_US.UTF-8 UTF-8\nde_DE.UTF-8 UTF-8\nnl_NL.UTF-8 UTF-8\npt_BR.UTF-8 UTF-8" > /etc/locale.gen && locale-gen
|
RUN echo "en_US.UTF-8 UTF-8\nde_DE.UTF-8 UTF-8\nnl_NL.UTF-8 UTF-8\npt_BR.UTF-8 UTF-8" > /etc/locale.gen && locale-gen
|
||||||
|
|
||||||
COPY docker/apache2.conf /etc/apache2/apache2.conf
|
COPY ./docker/apache2.conf /etc/apache2/apache2.conf
|
||||||
|
|
||||||
# Enable apache mod rewrite..
|
# Enable apache mod rewrite..
|
||||||
RUN a2enmod rewrite
|
RUN a2enmod rewrite
|
||||||
|
|
||||||
# Setup the Composer installer
|
# Setup the Composer installer
|
||||||
run curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
|
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
|
||||||
|
|
||||||
RUN cd /var/www && composer create-project grumpydictator/firefly-iii --no-dev --prefer-dist firefly-iii 4.6.4
|
# Copy Apache Configs
|
||||||
COPY docker/entrypoint.sh /var/www/firefly-iii/docker/entrypoint.sh
|
COPY ./docker/apache-firefly.conf /etc/apache2/sites-available/000-default.conf
|
||||||
ADD docker/apache-firefly.conf /etc/apache2/sites-available/000-default.conf
|
|
||||||
RUN chown -R www-data:www-data /var/www && chmod -R 775 /var/www/firefly-iii/storage
|
|
||||||
|
|
||||||
WORKDIR /var/www/firefly-iii
|
WORKDIR /var/www/firefly-iii
|
||||||
|
|
||||||
|
# The working directory
|
||||||
|
COPY . /var/www/firefly-iii/
|
||||||
|
|
||||||
|
RUN chown -R www-data:www-data /var/www && chmod -R 775 /var/www/firefly-iii/storage
|
||||||
|
|
||||||
|
RUN composer install --prefer-dist --no-dev --no-scripts
|
||||||
|
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|
||||||
ENTRYPOINT ["/var/www/firefly-iii/docker/entrypoint.sh"]
|
ENTRYPOINT ["/var/www/firefly-iii/docker/entrypoint.sh"]
|
||||||
|
Loading…
Reference in New Issue
Block a user