Fix Docker deployment: restore HTTPS, auto-run plugin migrations, install core plugins only

- Restore original HTTPS config in docker-compose files (gunicorn + gevent DOES support SSL)
- Add plugin migration step to docker-entrypoint.sh (fixes missing plugin tables on first deploy)
- Install only core plugins on bootstrap (backups, computers, endpoints, guides, knowledgebase, machines, network, notifications, printers, slides, tools, warranty)
- Set FLASK_ENV=production to disable Werkzeug debugger

Bug: bootstrap-plugins.sh installed ALL plugins but didn't run migrations, causing
'Table does not exist' errors. Now installs core plugins only and runs 'flask plugin
upgrade-all' after bootstrap.

Optional plugins (employees, geenforce, measuringtools, printedparts, usb) can be
installed later via Settings > Plugins.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Proudlock
2026-09-07 02:29:13 -04:00
parent d59cc89c48
commit 5767765ada
3 changed files with 36 additions and 17 deletions

View File

@@ -30,5 +30,12 @@ flask db upgrade || {
echo "==> Checking plugin installation"
/app/scripts/bootstrap-plugins.sh
# Run plugin migrations after bootstrap (creates tables for enabled plugins)
# Safe to run even if no plugins are enabled - it will just do nothing
echo "==> Running plugin migrations"
flask plugin upgrade-all || {
echo "WARNING: Plugin migrations failed - some features may not work"
}
echo "==> Starting application"
exec "$@"