mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-12-14 11:13:27 +01:00
Add DJANGO_SECRET_KEY support for Dispatcharr v0.13.1+ (#9730)
* Initial plan * Add DJANGO_SECRET_KEY support for Dispatcharr v0.13.1+ Co-authored-by: MickLesk <47820557+MickLesk@users.noreply.github.com> * Improve DJANGO_SECRET_KEY generation to ensure consistent 50 character length Co-authored-by: MickLesk <47820557+MickLesk@users.noreply.github.com> * short --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: MickLesk <47820557+MickLesk@users.noreply.github.com>
This commit is contained in:
@ -87,6 +87,11 @@ function update_script() {
|
||||
mv /tmp/start-daphne.sh.backup /opt/dispatcharr/start-daphne.sh
|
||||
fi
|
||||
|
||||
if ! grep -q "DJANGO_SECRET_KEY" /opt/dispatcharr/.env; then
|
||||
DJANGO_SECRET=$(openssl rand -base64 48 | tr -dc 'a-zA-Z0-9' | cut -c1-50)
|
||||
echo "DJANGO_SECRET_KEY=$DJANGO_SECRET" >> /opt/dispatcharr/.env
|
||||
fi
|
||||
|
||||
cd /opt/dispatcharr
|
||||
rm -rf .venv
|
||||
$STD uv venv
|
||||
|
||||
Reference in New Issue
Block a user