Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
8e9e429a
Commit
8e9e429a
authored
Jun 09, 2024
by
arkohut
Browse files
fix: tolerant readonly filesystem for copy favicon to static dir
parent
f2b9a5f5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
backend/config.py
backend/config.py
+6
-0
No files found.
backend/config.py
View file @
8e9e429a
...
...
@@ -310,6 +310,12 @@ if frontend_favicon.exists():
shutil
.
copyfile
(
frontend_favicon
,
STATIC_DIR
/
"favicon.png"
)
except
PermissionError
:
logging
.
error
(
f
"No write permission to
{
STATIC_DIR
/
'favicon.png'
}
"
)
except
OSError
as
e
:
if
e
.
errno
==
30
:
# Read-only file system
logging
.
error
(
f
"Read-only file system:
{
STATIC_DIR
/
'favicon.png'
}
"
)
else
:
logging
.
error
(
f
"OS error occurred:
{
e
}
"
)
else
:
logging
.
warning
(
f
"Frontend favicon not found at
{
frontend_favicon
}
"
)
...
...
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