Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Config with yml #1

Merged
merged 10 commits into from
Sep 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
/public/storage
/storage/*.key
/vendor
config.yml
.env
.env.backup
.phpunit.result.cache
Expand Down
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Everything needs to be reviewed by Alex
* @alexjustesen
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
/public/storage
/storage/*.key
/vendor
config.yml
.env
.env.backup
.phpunit.result.cache
Expand Down
2,102 changes: 2,102 additions & 0 deletions .phpstorm.meta.php

Large diffs are not rendered by default.

24 changes: 12 additions & 12 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,33 +3,33 @@ FROM serversideup/php:8.1-fpm-nginx
# Install addition packages
RUN apt-get update && apt-get install -y \
cron \
supervisor \
php8.1-bcmath \
php8.1-pgsql \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/* \
&& rm -f /etc/cont-init.d/50-laravel-automations
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /usr/share/doc/*

# Install Speedtest cli
RUN curl -s https://packagecloud.io/install/repositories/ookla/speedtest-cli/script.deb.sh | bash \
&& apt-get install -y speedtest

# Copy package configs
COPY docker/deploy/cron/scheduler /etc/cron.d/scheduler
COPY docker/deploy/entrypoint /usr/local/bin/entrypoint
COPY docker/deploy/etc/cont-init.d/ /etc/cont-init.d/
COPY docker/deploy/supervisord.conf /etc/supervisor/conf.d/supervisord.conf

RUN chmod 0644 /etc/cron.d/scheduler \
&& crontab /etc/cron.d/scheduler \
&& chmod +x /usr/local/bin/entrypoint
COPY docker/deploy/etc/services.d/ /etc/services.d/

# Copy app
COPY . /var/www/html
COPY .env.docker .env

# Install app dependencies
RUN composer install --no-interaction --prefer-dist --optimize-autoloader --no-dev \
&& chown -R 9999:9999 /var/www/html
&& mkdir -p /app \
&& mkdir -p storage/logs \
&& php artisan optimize:clear \
&& chown -R webuser:webgroup /var/www/html \
&& rm -rf /etc/cont-init.d/50-laravel-automations \
&& chmod 0644 /etc/cron.d/scheduler \
&& crontab /etc/cron.d/scheduler \
&& cp docker/deploy/entrypoint.sh /entrypoint \
&& chmod +x /entrypoint

ENTRYPOINT ["entrypoint"]
ENTRYPOINT ["/entrypoint"]
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ docker run -itd --name speedtest-tracker \
-p 8080:80 \
-e "PHP_POOL_NAME=speedtest-tracker_php" \
-e "DB_CONNECTION=sqlite" \
-e "DB_DATABASE=/appdata/database.sqlite" \
-v speedtest-tracker_app:/appdata \
-e "DB_DATABASE=/app/database.sqlite" \
-v speedtest-tracker_app:/app \
speedtest-tracker
```

Expand Down
Loading