FROM webdevops/php-nginx:8.3-alpine
# Installation dans votre Image du minimum pour que Docker fonctionne
RUN apk add oniguruma-dev libxml2-dev
RUN docker-php-ext-install \
bcmath \
ctype \
fileinfo \
mbstring \
pdo_mysql \
xml
# Installation dans votre image de Composer
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer
# Installation dans votre image de NodeJS
RUN apk add nodejs npm
ENV WEB_DOCUMENT_ROOT /app/public
ENV APP_ENV production
WORKDIR /app
COPY . .
# On copie le fichier .env.example pour le renommer en .env
# Vous pouvez modifier le .env.example pour indiquer la configuration de votre site pour la production
RUN cp -n .env.example .env
# Installation et configuration de votre site pour la production
# https://laravel.com/docs/10.x/deployment#optimizing-configuration-loading
RUN composer install --no-interaction --optimize-autoloader --no-dev
# Generate security key
RUN php artisan key:generate
# Optimizing Configuration loading
RUN php artisan config:cache
# Optimizing Route loading
RUN php artisan route:cache
# Optimizing View loading
RUN php artisan view:cache
# Compilation des assets de Breeze (ou de votre site)
RUN npm install
RUN npm run build
RUN chown -R application:application .
CMD ["sh", "-c", "run_migration_and_seed.sh"]
Adding this to my dockerfile taht only containe a php artisan migrate to test but it's not launch
#24 [stage-0 16/16] RUN chown -R application:application .
#24 DONE 4.8s
#25 exporting to image
#25 exporting layers
#25 exporting layers 8.1s done
#25 writing image sha256:ae2742756b94b1973d1f6dd0b9178e233c73a2a86f0ba7657b59e7e5a75f5b2d done
It's not appear here, can you help understand why?
thanks