aboutsummaryrefslogtreecommitdiff
path: root/modules/shared.py
diff options
context:
space:
mode:
authorAUTOMATIC1111 <16777216c@gmail.com>2022-09-08 11:46:51 +0300
committerGitHub <noreply@github.com>2022-09-08 11:46:51 +0300
commita196c45f15dc088e7162476729cf3bf28b0b3d73 (patch)
treee90b392fefa197780427abbfb2ce0d19ae62b109 /modules/shared.py
parent27dfcf69daf10b0c1e9b1844bb630dcc1898af50 (diff)
parentcce6f1df4117dc90cb16a07dc1634f0203c6bc0d (diff)
Merge pull request #146 from orionaskatu/orionaskatu-port-option
--port option for #131
Diffstat (limited to 'modules/shared.py')
-rw-r--r--modules/shared.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/shared.py b/modules/shared.py
index e529ec27..de7cbf02 100644
--- a/modules/shared.py
+++ b/modules/shared.py
@@ -34,6 +34,7 @@ parser.add_argument("--share", action='store_true', help="use share=True for gra
parser.add_argument("--esrgan-models-path", type=str, help="path to directory with ESRGAN models", default=os.path.join(script_path, 'ESRGAN'))
parser.add_argument("--opt-split-attention", action='store_true', help="enable optimization that reduced vram usage by a lot for about 10%% decrease in performance")
parser.add_argument("--listen", action='store_true', help="launch gradio with 0.0.0.0 as server name, allowing to respond to network requests")
+parser.add_argument("--port", type=int, help="launch gradio with given server port, you need root/admin rights for ports < 1024, defaults to 7860 if available", default=None)
cmd_opts = parser.parse_args()
if torch.has_cuda: