mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-08-28 22:01:33 +00:00
472cdca270
I've made various updates to the docker implementation to work with the latest php7 and currently blocks php8 until we deem nntmux ready. I've also made modifications that allow for customizations without leaving a dirty git status i.e. moving redis, etc. to an overrides file that is gitignored and php customizations i.e. locale to a local overrides file that is also gitignored. The new docker implementation utilizes supervisord to run various services in the web container, i.e. nginx, php-fpm, horizon, etc. I plan to continue to maintain this as needed. Closes #1152
43 lines
990 B
Bash
Executable File
43 lines
990 B
Bash
Executable File
#!/bin/bash
|
|
|
|
function _exec {
|
|
if [[ $IS_DOCKER == "true" ]]; then
|
|
${@:2}
|
|
else
|
|
docker-compose exec $@
|
|
fi
|
|
}
|
|
|
|
case $1 in
|
|
init)
|
|
touch docker/.zsh_history
|
|
touch docker/composer-auth.json
|
|
touch docker/php-overrides.local.ini
|
|
|
|
echo "Done!"
|
|
|
|
echo "Add any custom php configurations to docker/php-overrides.local.ini."
|
|
|
|
echo "Copy docker-compose.override.yml.dist to docker-compose.override.yml and remove any containers you do not want to run locally."
|
|
;;
|
|
link-logfile)
|
|
while true; do
|
|
ln -sf /dev/stdout /site/storage/logs/laravel-$(date +'%F').log
|
|
|
|
sleep 3600
|
|
done
|
|
;;
|
|
tmux-start)
|
|
_exec tmux php artisan tmux-ui:start
|
|
;;
|
|
tmux-restart)
|
|
_exec tmux php artisan tmux-ui:restart
|
|
;;
|
|
tmux-attach)
|
|
_exec tmux tmux attach
|
|
;;
|
|
tmux-stop)
|
|
_exec tmux php artisan tmux-ui:stop --kill
|
|
;;
|
|
esac
|