Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2571921
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
3 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/docker/swoole/rootfs/usr/local/bin/run-container b/docker/swoole/rootfs/usr/local/bin/run-container
index f565ce15..9337783d 100755
--- a/docker/swoole/rootfs/usr/local/bin/run-container
+++ b/docker/swoole/rootfs/usr/local/bin/run-container
@@ -1,42 +1,38 @@
#!/bin/bash
set -x
set -e
if [ -z "$@" ]; then
cd $(basename ${GIT_URI} .git)
if [ ! -z "${APP_SRC}" ]; then
cd ${APP_SRC}
fi
if [ ! -f ".env" -a -f ".env.example" ]; then
mv .env.example .env
fi
if [ -z "${APP_KEY}" ]; then
./artisan key:generate
unset APP_KEY
fi
- if [ -z "${JWT_SECRET}" ]; then
- ./artisan jwt:secret -f
- fi
-
./artisan clear-compiled
# This should not occur in production
#./artisan cache:clear
# A standalone environment doesn't have anything to ping
#timeout 10m ./artisan db:ping --wait
./artisan migrate
env
exec ./artisan octane:start
else
exec $@
fi
diff --git a/src/.s2i/bin/run b/src/.s2i/bin/run
index 42f8f743..d1a86316 100755
--- a/src/.s2i/bin/run
+++ b/src/.s2i/bin/run
@@ -1,94 +1,89 @@
#!/bin/bash
shopt -s dotglob
pushd /opt/app-root/src
echo "----> Remove bootstrap cache"
find bootstrap/cache/ -type f ! -name ".gitignore" -delete
if [ -z ${APP_KEY} ]; then
echo "----> Run artisan key:generate"
./artisan key:generate
unset APP_KEY
fi
-if [ -z ${JWT_SECRET} ]; then
- echo "----> Run artisan jwt:secret"
- ./artisan jwt:secret --always-no
-fi
-
echo "----> Run artisan clear-compiled"
./artisan clear-compiled
if [ "${LARAVEL_ENV}" != "production" -a "${LARAVEL_ENV}" != "prod" ]; then
echo "----> Run artisan cache:clear"
./artisan ${ARTISAN_VERBOSITY} cache:clear || true
fi
# rpm -qv chromium
# if [ ! -z "$(rpm -qv chromium 2>/dev/null)" ]; then
# echo "---- Run artisan dusk:chrome-driver"
# chver=$(rpmquery --queryformat="%{VERSION}" chromium | awk -F'.' '{print $1}')
# ./artisan dusk:chrome-driver ${chver}
# fi
if [ ! -f 'resources/countries.php' ]; then
echo "----> Run artisan data:countries"
./artisan data:countries
fi
rm -rvf bootstrap/cache/
mkdir -vp bootstrap/cache/
chown default bootstrap/cache
./artisan db:ping --wait || exit 1
if [ ! -z "${OPENEXCHANGERATES_API_KEY}" ]; then
./artisan data:import:open-exchange-rates
fi
if [ -z "${KOLAB_ROLE}" -a ! -z "${HKCCP_APP}" ]; then
echo "WARNING: Use env KOLAB_ROLE, not HKCCP_APP"
KOLAB_ROLE=$HKCCP_APP
fi
case ${KOLAB_ROLE} in
apache|APACHE|httpd|HTTPD)
echo "----> Starting httpd"
/usr/libexec/s2i/run 2>&1
;;
horizon|HORIZON)
./artisan migrate --force || :
echo "----> Starting horizon"
./artisan horizon
;;
octane|OCTANE)
echo "----> Running octane"
exec ./artisan octane:start --host=0.0.0.0
;;
server|SERVER)
echo "----> Running server"
exec ./artisan serve
;;
swoole|SWOOLE )
echo "----> WARNING: Role is swoole but must become octane"
echo "----> Running octane"
exec ./artisan octane:start --host=0.0.0.0
;;
worker|WORKER )
./artisan migrate --force || :
echo "----> Running worker"
exec ./artisan queue:work
;;
* )
echo "----> Sleeping"
exec sleep 10000
;;
esac
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Thu, Mar 19, 10:18 AM (1 d, 9 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
458005
Default Alt Text
(3 KB)
Attached To
Mode
R2 kolab
Attached
Detach File
Event Timeline
Log In to Comment