Fix initial setup

This commit is contained in:
Fabián Gonzalo Artur de la Villarmois
2025-12-26 20:10:49 +13:00
parent eb4f5fd561
commit a75f504dd5
2 changed files with 16 additions and 6 deletions
+16 -5
View File
@@ -12,11 +12,22 @@ COPY ./www .
# Remove vendor and node_modules if they exist (to ensure clean install)
RUN rm -rf vendor node_modules
# Install composer dependencies during build
RUN composer install --no-interaction --optimize-autoloader --no-dev
# Install composer dependencies
RUN composer install --no-interaction --optimize-autoloader
# Install npm dependencies and build during build
# Copy .env.example to .env
RUN cp .env.example .env
# Generate application key
RUN php artisan key:generate
# Install npm dependencies and build
RUN npm install && npm run build
# Create storage link during build
RUN php artisan storage:link
# Create storage link
RUN php artisan storage:link
# Fix permissions for Laravel storage and bootstrap/cache
# Use numeric IDs (1000:1000 from PUID/PGID in docker-compose)
RUN chown -R 1000:1000 /app/www && \
chmod -R 775 /app/www/storage /app/www/bootstrap/cache
-1
View File
@@ -8,7 +8,6 @@ services:
- PGID=1000
- TZ=Etc/UTC
volumes:
- ./www:/app/www
- ./games:/app/www/storage/app/public/games
ports:
- 8030:80