Closed maleldil closed 1 month ago
I mistakenly selected the wrong item from the version dropdown. Version is latest Bluefin stable, TrueNAS-SCALE-22.12.0. I've edited the original report accordingly.
Its an upstream bug and we already are short on devtime. Not going ti fix upstream application issues.
While there is a bug filed upstream, it doesn't look to necessarily be a bug in the software, but rather a configuration requirement when using postgresql as the database backend. The Airsonic documentation states "Setting stringtype=unspecified on your JDBC url string is necessary for now for compatibility." when using postgresql (https://airsonic.github.io/docs/database/#postgresql). As it stands, since the admin user cannot change their password, and cannot create new users, the chart is unsuitable for exposing to the internet via ingress, as all instances will have a user/password of admin/admin. I believe the fix would be a simple change to the env
section of charts/stable/airsonic-advanced/values.yaml
as below:
env:
AIRSONIC_DIR: "/"
# -- For passing additional java options. For some reverse proxies, you may need to pass `JAVA_OPTS=-Dserver.use-forward-headers=true` for airsonic to generate the proper URL schemes.
JAVA_OPTS:
CONTEXT_PATH: "/"
spring_liquibase_parameters_userTableQuote: '"'
spring_datasource_username: "{{ .Values.postgresql.postgresqlUsername }}"
spring_datasource_url_base:
secretKeyRef:
name: dbcreds
key: jdbc
spring_datasource_url: "{{ .Values.env.spring_datasource_url_base }}?stringtype=unspecified"
spring_datasource_password:
secretKeyRef:
name: dbcreds
key: postgresql-password
I've renamed the original jdbc url to spring_datasource_url_base
and redefined spring_datasource_url
to be the concatenation of the original url with the required parameter added.
Please note that I am not a seasoned kubernetes developer, otherwise I would submit a pull request, but I don't know if there are other considerations I may be missing.
While there is a bug filed upstream, it doesn't look to necessarily be a bug in the software, but rather a configuration requirement when using postgresql as the database backend. The Airsonic documentation states "Setting stringtype=unspecified on your JDBC url string is necessary for now for compatibility." when using postgresql (https://airsonic.github.io/docs/database/#postgresql). As it stands, since the admin user cannot change their password, and cannot create new users, the chart is unsuitable for exposing to the internet via ingress, as all instances will have a user/password of admin/admin. I believe the fix would be a simple change to the
env
section ofcharts/stable/airsonic-advanced/values.yaml
as below:env: AIRSONIC_DIR: "/" # -- For passing additional java options. For some reverse proxies, you may need to pass `JAVA_OPTS=-Dserver.use-forward-headers=true` for airsonic to generate the proper URL schemes. JAVA_OPTS: CONTEXT_PATH: "/" spring_liquibase_parameters_userTableQuote: '"' spring_datasource_username: "{{ .Values.postgresql.postgresqlUsername }}" spring_datasource_url_base: secretKeyRef: name: dbcreds key: jdbc spring_datasource_url: "{{ .Values.env.spring_datasource_url_base }}?stringtype=unspecified" spring_datasource_password: secretKeyRef: name: dbcreds key: postgresql-password
I've renamed the original jdbc url to
spring_datasource_url_base
and redefinedspring_datasource_url
to be the concatenation of the original url with the required parameter added.Please note that I am not a seasoned kubernetes developer, otherwise I would submit a pull request, but I don't know if there are other considerations I may be missing.
To be clear: We officially don't even support other authentication then basic and forward auth on Ingress at all for internet exposure ;-)
reopening, please next time don't suggest it's a bug upstream, if upstream doesn't qualify it as such.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in two weeks if no further activity occurs. Thank you for your contributions.
Not stale; this issue still seems to be present.
Still not working in october 2023 on latest Truenas scale
This is still an issue as of 2024 02 08 - fresh install from scale repo fails as above. Without change to the initial configuration when deployed per the DB connect string, this will not be a viable app.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in two weeks if no further activity occurs. Thank you for your contributions.
This issue has been automatically closed due to inactivity. Please re-open if this still requires investigation.
App Name
airsonic-advanced
SCALE Version
22.12.0
App Version
11.0.0_7.0.19
Application Events
Application Logs
Application Configuration
The only change from defaults is using a Host Path for the App Music Storage mount. Playing music works fine, btw.
Describe the bug
Internal server error when updating the current user or attempting to create a new user.
To Reproduce
Expected Behavior
Admin user email address should be updated. The same error happens when attempting to create a new user, or modify any user settings.
Screenshots
Additional Context
There's an open issue for this on the airsonic-advanced project (https://github.com/airsonic-advanced/airsonic-advanced/issues/896), but it looks like there is a workaround that could be applied to the TrueCharts configuration for this app that would resolve it for TrueNAS SCALE users. The documentation (https://airsonic.github.io/docs/database/#postgresql) for Airsonic Advanced says that for postgresql databases we need to append
?stringtype=unspecified
to the jdbc connection string. Example:jdbc:postgresql://localhost:5432/airsonic?stringtype=unspecified
In this chart this looks to be managed by the
spring_datasource_url
environment variable, but this cannot be overridden by the user in the current version.I've read and agree with the following