Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
S
stable-diffusion-webui
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
stable-diffusion-webui
Commits
372a2c3e
Commit
372a2c3e
authored
Sep 12, 2022
by
AUTOMATIC
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Feature Request] Please add "--share-password" for Gradio server security #315
parent
e4f080f6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
2 deletions
+10
-2
shared.py
modules/shared.py
+3
-1
webui.py
webui.py
+7
-1
No files found.
modules/shared.py
View file @
372a2c3e
...
@@ -42,7 +42,9 @@ parser.add_argument("--show-negative-prompt", action='store_true', help="does no
...
@@ -42,7 +42,9 @@ parser.add_argument("--show-negative-prompt", action='store_true', help="does no
parser
.
add_argument
(
"--ui-config-file"
,
type
=
str
,
help
=
"filename to use for ui configuration"
,
default
=
os
.
path
.
join
(
script_path
,
'ui-config.json'
))
parser
.
add_argument
(
"--ui-config-file"
,
type
=
str
,
help
=
"filename to use for ui configuration"
,
default
=
os
.
path
.
join
(
script_path
,
'ui-config.json'
))
parser
.
add_argument
(
"--hide-ui-dir-config"
,
action
=
'store_true'
,
help
=
"hide directory configuration from webui"
,
default
=
False
)
parser
.
add_argument
(
"--hide-ui-dir-config"
,
action
=
'store_true'
,
help
=
"hide directory configuration from webui"
,
default
=
False
)
parser
.
add_argument
(
"--ui-settings-file"
,
type
=
str
,
help
=
"filename to use for ui settings"
,
default
=
os
.
path
.
join
(
script_path
,
'config.json'
))
parser
.
add_argument
(
"--ui-settings-file"
,
type
=
str
,
help
=
"filename to use for ui settings"
,
default
=
os
.
path
.
join
(
script_path
,
'config.json'
))
parser
.
add_argument
(
"--gradio-debug"
,
action
=
'store_true'
,
help
=
"launch gradio with --debug option"
)
parser
.
add_argument
(
"--gradio-debug"
,
action
=
'store_true'
,
help
=
"launch gradio with --debug option"
)
parser
.
add_argument
(
"--gradio-username"
,
type
=
str
,
help
=
"username for gradio authentication; default: user"
,
default
=
"user"
)
parser
.
add_argument
(
"--gradio-password"
,
type
=
str
,
help
=
"password for gradio authentication; default: no authentication"
,
default
=
None
)
cmd_opts
=
parser
.
parse_args
()
cmd_opts
=
parser
.
parse_args
()
...
...
webui.py
View file @
372a2c3e
...
@@ -115,7 +115,13 @@ def webui():
...
@@ -115,7 +115,13 @@ def webui():
run_pnginfo
=
modules
.
extras
.
run_pnginfo
run_pnginfo
=
modules
.
extras
.
run_pnginfo
)
)
demo
.
launch
(
share
=
cmd_opts
.
share
,
server_name
=
"0.0.0.0"
if
cmd_opts
.
listen
else
None
,
server_port
=
cmd_opts
.
port
,
debug
=
cmd_opts
.
gradio_debug
)
demo
.
launch
(
share
=
cmd_opts
.
share
,
server_name
=
"0.0.0.0"
if
cmd_opts
.
listen
else
None
,
server_port
=
cmd_opts
.
port
,
debug
=
cmd_opts
.
gradio_debug
,
auth
=
(
cmd_opts
.
gradio_username
,
cmd_opts
.
gradio_password
)
if
cmd_opts
.
gradio_password
is
not
None
else
None
,
)
if
__name__
==
"__main__"
:
if
__name__
==
"__main__"
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment