hrfee / jfa-go

a bit-of-everything user managament app for Jellyfin
https://jfa-go.com
Other
804 stars 57 forks source link

Crashing on start after config #256

Open Gandalf-the-Blue opened 1 year ago

Gandalf-the-Blue commented 1 year ago

Read the FAQ first!

Describe the bug

Jfa-go crashes after setup. Cannot access crash logs, can't see file.

Logs

2023/02/27 11:27:16 Using external storage
jfa-go version: 0.4.0 (c6fc576)
Socket: /tmp/jfa-go.sock
[INFO] 11:27:16  Using Jellyfin server type
[INFO] 11:27:16  Authenticated with "!redacted!"
[INFO] 11:27:16  User daemon started
[INFO] 11:27:16  Starting password reset daemon
[INFO] 11:27:16  Invite daemon started
[INFO] 11:27:16  Initializing router
[INFO] 11:27:16  Loading routes
wildcards must be named with a non-empty name in path '/!jfa-go base url!/accounts/lang/:page'
2023/02/27 11:27:16 
------
A crash report has been saved to "/tmp/jfa-go-crash-2023-02-27T11:27:16.txt".

Config

first_run = false

[updates]
; settings for update notifications and release channel.
; enable/disable updating notifications and downloading/applying updates.
enabled = true
; release channel for updates.
channel = 

[jellyfin]
; settings for connecting to jellyfin
; it is recommended to create a limited admin account for this program.
username                    = redacted
password                    = redacted
; jellyfin server address. can be public, or local for security purposes.
server                      = http://ip:port
; publicly accessible jellyfin address for invite form. leave blank to reuse the above address.
public_server               = https://jellyfin.domain.tld/
; the name of the client that will show up in the jellyfin dashboard.
client                      = jfa-go
; timeout of user cache in minutes. set to 0 to disable.
cache_timeout               = 30
; note: emby integration works but is missing some features, such as password resets.
type                        = jellyfin
; optionally substitute occurrences of "jellyfin" in the account creation form and emails with this. may result in bad grammar.
substitute_jellyfin_strings = redacted

[ui]
; settings related to the ui and program functionality.
; default account form language. visit weblate.jfa-go.com if you'd like to translate.
language-form   = en-gb
; default admin page language. settings has not been translated. visit weblate.jfa-go.com if you'd like to translate.
language-admin  = en-gb
; default appearance for all users.
theme           = Jellyfin (Dark)
; set 0.0.0.0 to run on localhost
host            = internal ip
port            = port
; enable this to use jellyfin users instead of the below username and pw.
jellyfin_login  = true
; allows only admin users on jellyfin to access the admin page.
admin_only      = true
; allow all jellyfin users to access jfa-go. not recommended, add individual users in the accounts tab instead.
allow_all       = false
; username for admin page (leave blank if using jellyfin_login)
username        = your username
; password for admin page (leave blank if using jellyfin_login)
password        = your password
; address to send notifications to (leave blank if using jellyfin_login)
email           = example@example.com
; enables debug logging and exposes pprof as a route (don't use in production!)
debug           = false
; displayed at bottom of all pages except admin
contact_message = Need help? contact me.
; displayed at top of invite form.
help_message    = Enter your details to create an account.
; displayed when a user creates an account
success_message = Your account has been created. Please continue to redacted
; url base for when running jfa-go with a reverse proxy in a subfolder. include preceding /, e.g "/accounts".
url_base        = https://jfago.domain.tld/accounts
; set a different url for the sign-up form to redirect the user to when they've signed up. default to 'public server' or 'server' in the jellyfin tab.
redirect_url    = 

[advanced]
; advanced settings.
; enable tls.
tls      = false
; port to run tls server on
tls_port = 8057
; path to .crt file. see jfa-go wiki for more info.
tls_cert = 
; path to .key file. see jfa-go wiki for more info.
tls_key  = 

[captcha]
; settings related to user creation captchas.
; enable a captcha on the account creation form.
enabled = false

[password_validation]
; password validation (minimum length, etc.)
enabled    = true
min_length = 12
upper      = 1
lower      = 0
number     = 1
special    = 1

[messages]
; general settings for emails/messages.
; enable the sending of emails/messages such as password resets, announcements, etc.
enabled     = true
use_24h     = true
; date format used in emails. follows datetime.strftime format.
date_format = %d/%m/%y
; message displayed at bottom of emails.
message     = Need help? contact me.

[email]
; general email settings.
; default email language. submit a pr on github if you'd like to translate.
language    = en-gb
; use email address from invite form as username on jellyfin.
no_username = false
; method of sending email to use.
method      = smtp
; address to send emails from
address     = redacted
; the name of the sender
from        = redacted
; send emails as plain text instead of html.
plaintext   = false
; require an email address on sign-up.
required    = false

[mailgun]
; mailgun api connection settings
api_url = https://api.mailgun.net...
api_key = your api key

[smtp]
; smtp server connection settings.
; username for smtp. leave blank to user send from address as username.
username        = redacted
; your email provider should provide different ports for each encryption method. generally 465 for ssl_tls, 587 for starttls.
encryption      = starttls
; smtp server address.
server          = redacted
port            = 465
password        = redacted
; hostname sent when sending hello to the smtp server. some servers don't like the default "localhost" value, such as smtp-relay.gmail.com.
hello_hostname  = localhost
; use if your smtp server's ssl certificate is not trusted by the system.
ssl_cert        = 
; warning, disabling this makes you much more vulnerable to man-in-the-middle attacks
cert_validation = true

[discord]
; settings for discord invites/signup/notifications
; enable signup verification through discord and the sending of notifications through it.
; see the jfa-go wiki for setting up a bot.
enabled        = false
; allow users to link their discord on the registration page.
show_on_reg    = true
; require discord connection on sign-up. see the jfa-go wiki for info on setting this up.
required       = false
; discord bot api token.
token          = 
; command to start the user verification process.
start_command  = start
; only listen to commands in specified channel. leave blank to monitor all.
channel        = 
; generate a one-time discord server invite for the account creation form. required bot permission "create instant invite", you may need to re-add the bot to your server after.
provide_invite = false
; channel to invite new users to.
invite_channel = 
; add the selected role to a user when they sign up.
apply_role     = 
; default discord message language. visit weblate if you'd like to translate.
language       = en-us

[telegram]
; settings for telegram signup/notifications. see the jfa-go wiki for info on setting this up.
; enable signup verification through telegram and the sending of notifications through it.
; see the jfa-go wiki for setting up a bot.
enabled     = false
; allow users to link their telegram on the registration page.
show_on_reg = true
; require telegram connection on sign-up.
required    = false
; telegram bot api token.
token       = 
; default telegram message language. visit weblate if you'd like to translate.
language    = en-us

[matrix]
; settings for matrix invites/signup/notifications. see the jfa-go wiki for info on setting this up.
; enable signup verification through matrix and the sending of notifications through it.
; see the jfa-go wiki for setting up a bot.
enabled     = false
; allow users to link their matrix on the registration page.
show_on_reg = true
; require matrix connection on sign-up.
required    = false
; matrix home server url.
homeserver  = 
; matrix bot api token.
token       = 
; user id of bot account (example: @jfa-bot:riot.im)
user_id     = 
; topic of matrix private chats.
topic       = Jellyfin notifications
; default matrix message language. visit weblate if you'd like to translate.
language    = en-us
; enable end-to-end encryption for messages. very experimental, currently does not support receiving commands (e.g !lang).
encryption  = false

[password_resets]
; settings for the password reset handler.
; enable to store provided email addresses, monitor jellyfin directory for pw-resets, and send reset pins
enabled         = true
; path to the folder jellyfin puts password-reset files.
watch_directory = /jf
; send users a link to reset their password instead of a pin. must be enabled to reset ombi password at the same time as the jellyfin password.
link_reset      = true
; instead of automatically setting the user's password to the pin, allow them to set a new password through the reset link.
set_password    = true
; base url for jfa-go. you can leave this if you have one set in "invite emails". this is necessary because using a reverse proxy means the program has no way of knowing the url itself.
url_base        = https://jfago.domain.tld
; default language for password reset success screen.
language        = en-gb
; path to custom email html
email_html      = 
; path to custom email in plain text
email_text      = 
; subject of password reset emails.
subject         =  redacted

[invite_emails]
; settings for sending invites directly to users.
enabled    = true
; path to custom email html
email_html = 
; path to custom email in plain text
email_text = 
; subject of invite emails.
subject    = Invitation to Jellyfin
; base url for jfa-go. this is necessary because using a reverse proxy means the program has no way of knowing the url itself.
url_base   = https://jfago.domain.tld/invite

[template_email]
; settings for the template used for announcements & custom messages. html should include {{ .text }}, plaintext should include {{ .plaintext }}, and either can have {{ .message }} to include the contact message.
; path to custom email html template for announcements/custom messages.
email_html = 
; path to custom email text template for announcements/custom messages.
email_text = 

[notifications]
; notification related settings.
; enabling adds optional toggles to invites to notify on expiry and user creation.
enabled      = true
; path to expiry notification email html.
expiry_html  = 
; path to expiry notification email in plaintext.
expiry_text  = 
; path to user creation notification email html.
created_html = 
; path to user creation notification email in plaintext.
created_text = 

[ombi]
; connect to ombi to automatically create both ombi and jellyfin accounts for new users. you'll need to add a ombi template to an existing user profile for accounts to be created, which you can do by refreshing then checking settings > user profiles. to handle password resets for ombi & jellyfin, enable "use reset link instead of pin".
; enable to create an ombi account for new jellyfin users
enabled = true
; ombi server url, including http(s)://.
server  = https://ombi.domain.tld/
; api key. get this from the first tab in ombi settings.
api_key = redacted

[welcome_email]
; optionally send a welcome message to new users with the jellyfin url and their username.
; enable to send welcome emails to new users.
enabled    = true
; subject of welcome emails.
subject    = redacted
; path to custom email html
email_html = 
; path to custom email in plain text
email_text = 

[email_confirmation]
; if enabled, a user will be sent an email confirmation link to ensure their password is right before they can make an account.
enabled    = false
; subject of email confirmation emails.
subject    = 
; path to custom email html
email_html = 
; path to custom email in plain text
email_text = 

[user_expiry]
; when set on an invite, users will be deleted or disabled a specified amount of time after they create their account.
; whether to delete or disable users on expiry.
behaviour  = disable_user
; send an email when a user's account expires.
send_email = true
; subject of user expiry emails.
subject    = 
; path to custom email html
email_html = 
; path to custom email in plain text
email_text = 

[disable_enable]
; subject/email files for account disabling/enabling emails.
; subject of account disabling emails.
subject_disabled = 
; subject of account enabling emails.
subject_enabled  = 
; path to custom email html
disabled_html    = 
; path to custom email in plain text
disabled_text    = 
enabled_html     = 
enabled_text     = 

[deletion]
; subject/email files for account deletion emails.
; subject of account deletion emails.
subject    = 
; path to custom email html
email_html = 
; path to custom email in plain text
email_text = 

[files]
; optional settings for changing storage locations.
; location of stored invites (json).
invites         = 
; location of stored non-jellyfin password resets (json).
password_resets = 
; location of stored email addresses (json).
emails          = 
; stores users temporarily when a user expiry is set.
users           = 
; location of stored ombi user template.
ombi_template   = 
; location of stored user profiles (encompasses template and configuration and displayprefs) (json)
user_profiles   = 
; path to directory containing custom versions of web ui pages. see wiki for more info.
html_templates  = 
; the path to a directory which following the same form as the internal 'lang/' directory. see github for more info.
lang_files      = 
; json file generated by program in settings, different from email_html/email_text. see wiki for more info.
custom_emails   = 
; stores telegram user ids and language preferences.
telegram_users  = 
; stores matrix user ids and language preferences.
matrix_users    = 
; stores cryptographic material for matrix end-to-end encryption.
matrix_sql      = 
; stores discord user ids and language preferences.
discord_users   = 
; stores custom announcement templates.
announcements   = 

Platform/Version

Docker. Latest from docker hub

BLACK4585 commented 10 months ago

Same problem here

hrfee commented 9 months ago

[ui]/url_base, a.k.a General -> Reverse Proxy Subfolder should be only the subfolder, i.e. if my jfa-go URL was jellyfin.my.site/accounts, the setting would be set to "/accounts".