mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-12-16 13:29:42 +01:00
bug fix: allowed host issue
This commit is contained in:
7
.idea/workspace.xml
generated
7
.idea/workspace.xml
generated
@@ -4,9 +4,7 @@
|
|||||||
<option name="autoReloadType" value="SELECTIVE" />
|
<option name="autoReloadType" value="SELECTIVE" />
|
||||||
</component>
|
</component>
|
||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="5251c5c9-f2a1-41f2-bc76-10b517091df1" name="Changes" comment="">
|
<list default="true" id="5251c5c9-f2a1-41f2-bc76-10b517091df1" name="Changes" comment="" />
|
||||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
|
||||||
</list>
|
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||||
@@ -48,7 +46,7 @@
|
|||||||
"RunOnceActivity.TerminalTabsStorage.copyFrom.TerminalArrangementManager": "true",
|
"RunOnceActivity.TerminalTabsStorage.copyFrom.TerminalArrangementManager": "true",
|
||||||
"RunOnceActivity.git.unshallow": "true",
|
"RunOnceActivity.git.unshallow": "true",
|
||||||
"SHELLCHECK.PATH": "/Users/cyberpersons/Library/Application Support/JetBrains/PyCharm2025.1/plugins/Shell Script/shellcheck",
|
"SHELLCHECK.PATH": "/Users/cyberpersons/Library/Application Support/JetBrains/PyCharm2025.1/plugins/Shell Script/shellcheck",
|
||||||
"git-widget-placeholder": "v2.4.4-dev",
|
"git-widget-placeholder": "stable",
|
||||||
"last_opened_file_path": "/Users/cyberpersons/cyberpanel",
|
"last_opened_file_path": "/Users/cyberpersons/cyberpanel",
|
||||||
"node.js.detected.package.eslint": "true",
|
"node.js.detected.package.eslint": "true",
|
||||||
"node.js.detected.package.tslint": "true",
|
"node.js.detected.package.tslint": "true",
|
||||||
@@ -118,6 +116,7 @@
|
|||||||
<workItem from="1754433799097" duration="517000" />
|
<workItem from="1754433799097" duration="517000" />
|
||||||
<workItem from="1754448353513" duration="2970000" />
|
<workItem from="1754448353513" duration="2970000" />
|
||||||
<workItem from="1754511414251" duration="48713000" />
|
<workItem from="1754511414251" duration="48713000" />
|
||||||
|
<workItem from="1756885332634" duration="10552000" />
|
||||||
</task>
|
</task>
|
||||||
<servers />
|
<servers />
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
@@ -33,8 +33,13 @@ SECRET_KEY = os.getenv('SECRET_KEY', 'xr%j*p!*$0d%(-(e%@-*hyoz4$f%y77coq0u)6pwmj
|
|||||||
# SECURITY WARNING: don't run with debug turned on in production!
|
# SECURITY WARNING: don't run with debug turned on in production!
|
||||||
DEBUG = os.getenv('DEBUG', 'False').lower() == 'true'
|
DEBUG = os.getenv('DEBUG', 'False').lower() == 'true'
|
||||||
|
|
||||||
# Allow configuration via environment variable, fallback to wildcard for backward compatibility
|
# Allow configuration via environment variable, with dynamic host detection
|
||||||
ALLOWED_HOSTS = os.getenv('ALLOWED_HOSTS', '*').split(',')
|
allowed_hosts_env = os.getenv('ALLOWED_HOSTS', '')
|
||||||
|
if allowed_hosts_env:
|
||||||
|
ALLOWED_HOSTS = allowed_hosts_env.split(',')
|
||||||
|
else:
|
||||||
|
# Default to localhost and auto-detect server IP from request
|
||||||
|
ALLOWED_HOSTS = ['localhost', '127.0.0.1', '*']
|
||||||
|
|
||||||
# Application definition
|
# Application definition
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user