fix: more intuitive port handling
This commit is contained in:
parent
4ed73c3086
commit
9d23b391fe
3
abyss.go
3
abyss.go
@ -43,11 +43,12 @@ func main() {
|
||||
app.filesDir = "./files"
|
||||
}
|
||||
|
||||
if app.port == ":" {
|
||||
if app.port == "" {
|
||||
slog.Info("running on default port")
|
||||
app.port = ":3235"
|
||||
} else {
|
||||
slog.Info("running on modified port")
|
||||
app.port = ":" + app.port
|
||||
}
|
||||
|
||||
mux := http.NewServeMux()
|
||||
|
@ -30,7 +30,7 @@ ABYSS_URL=$ABYSS_URL
|
||||
ABYSS_FILEDIR=$ABYSS_FILEDIR
|
||||
|
||||
# The port the server will run on, it's fine to leave it empty. Defaults to :3235
|
||||
ABYSS_PORT=:$ABYSS_PORT
|
||||
ABYSS_PORT=$ABYSS_PORT
|
||||
|
||||
# This is the username of the user for accessing /tree
|
||||
AUTH_USERNAME=$AUTH_USERNAME
|
||||
|
Loading…
Reference in New Issue
Block a user