39 lines
1.1 KiB
Bash
Executable File
39 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
||
set -eo pipefail
|
||
|
||
# Se positionner sur la racine du projet
|
||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
||
cd ${DIR}
|
||
cd ../..
|
||
DIR=$(pwd)
|
||
|
||
bin/console d:s:u --force --complete
|
||
|
||
yarn encore prod
|
||
|
||
# Asset media de base
|
||
mkdir -p /app/public/uploads
|
||
mkdir -p /app/public/uploads/logo
|
||
mkdir -p /app/public/uploads/image
|
||
mkdir -p /app/public/uploads/hero
|
||
mkdir -p /app/public/uploads/avatar
|
||
|
||
chown apache /app/public/uploads
|
||
chown apache /app/public/uploads/logo
|
||
chown apache /app/public/uploads/image
|
||
chown apache /app/public/uploads/hero
|
||
chown apache /app/public/uploads/avatar
|
||
|
||
cp -f /app/public/styles/medias/admin.jpg /app/public/uploads/avatar/
|
||
cp -f /app/public/styles/medias/noavatar.png /app/public/uploads/avatar/
|
||
cp -f /app/public/styles/medias/system.jpg /app/public/uploads/avatar/
|
||
cp -f /app/public/styles/medias/hero.jpg /app/public/uploads/hero/
|
||
cp -f /app/public/styles/medias/contact.jpg /app/public/uploads/image/
|
||
cp -f /app/public/styles/medias/link.jpg /app/public/uploads/image/
|
||
cp -f /app/public/styles/medias/logo.png /app/public/uploads/logo/
|
||
|
||
|
||
bin/console app:AppInit
|
||
bin/console app:CronInit
|
||
|
||
exec $@ |