Skip to content

Commit 8200482

Browse files
authored
670 feature request add support for qobuz new authentication mode (#671)
* #670 qobuz authentication review * #670 complete with documentation - add remarks in the generated upmpdcli.conf file - add entry in News section of README.md
1 parent 54d0958 commit 8200482

5 files changed

Lines changed: 22 additions & 26 deletions

File tree

Dockerfile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -154,8 +154,6 @@ ENV CHECK_CONTENT_FORMAT=""
154154

155155
ENV QOBUZ_ENABLE=no
156156
ENV QOBUZ_TITLE=""
157-
ENV QOBUZ_USERNAME="qobuz_username"
158-
ENV QOBUZ_PASSWORD="qobuz_password"
159157
ENV QOBUZ_FORMAT_ID=5
160158
ENV QOBUZ_RENUM_TRACKS=""
161159
ENV QOBUZ_EXPLICIT_ITEM_NUMBERS=""

README.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,13 @@ Current version is `1.9.17`.
2323

2424
## News (newest first)
2525

26+
### Support for the updated qobuz authentication method
27+
28+
The former authentication method, based on username and password, doesn't work anymore.
29+
So the variables `QOBUZ_USERNAME` and `QOBUZ_PASSWORD` have been removed.
30+
By setting `QOBUZ_ENABLE` to `yes`, the initialization script will set the `qobuzuser` configuration key to `qobuz` just to enable the mediaserver.
31+
You will need to run the `qobuz-init-auth.py` script from inside the container, as mentioned in the [Qobuz example configuration](./doc/example-configurations.md#qobuz).
32+
2633
### Download variables deprecated
2734

2835
We can now avoid to download plugin at runtime. Just use updated master/edge images (see below).
@@ -281,8 +288,6 @@ TIDAL_ALLOW_STATISTICS_ACTIONS|Allow the creation of entries that can remove ent
281288
TIDAL_ENABLE_USER_AGENT_WHITELIST|Enables the agent whitelist for hi-res support, default is `yes`
282289
QOBUZ_ENABLE|Set to `yes` to enable Qobuz support, defaults to `no`
283290
QOBUZ_TITLE|Set the title for Qobuz plugin, defaults to `Qobuz`
284-
QOBUZ_USERNAME|Your Qobuz account username
285-
QOBUZ_PASSWORD|Your Qobuz account password
286291
QOBUZ_FORMAT_ID|Qobuz format id: 5 for mp3/320, 6 for FLAC, 7 for FLAC 24/96, 27 for hi-res, defaults to `5`
287292
QOBUZ_RENUM_TRACKS|Renum tracks in albums and playlists, mostly for kodi compatibility, defaults to `1`
288293
QOBUZ_EXPLICIT_ITEM_NUMBERS|Adds numbers in square brackets in list items, mostly for kodi compatibility, defaults to `0`
@@ -323,11 +328,10 @@ FILE|DESCRIPTION
323328
:---|:---
324329
additional-radio-list.txt|Additional Radios
325330
recoll.conf.user|Recoll configuration (used by upcrl)
326-
qobuz.txt|Qobuz Credentials
327331
hra.txt|HRA Credentials, format is like a .env file. Make sure you include all the settings related the streaming service.
328332
upmpdcli-additional.txt|Configuration snippet, will be appended to upmpdcli.conf.
329333

330-
For `qobuz.txt` and `hra.txt`, the format of the file must be like a `.env` file, where all the settings which are related to the service must be listed. Mixed configurations (so part in variables, part in these files) are not supported.
334+
For `hra.txt`, the format of the file must be like a `.env` file, where all the settings which are related to the service must be listed. Mixed configurations (so part in variables, part in these files) are not supported.
331335
The upmpdcli-additional.txt is a simple list of lines with a `key = value` synthax.
332336

333337
### Custom icon

app/bin/run-upmpdcli.sh

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ fi
4848
SOURCE_CONFIG_FILE=/app/conf/upmpdcli.conf
4949
CONFIG_FILE=/tmp/current-upmpdcli.conf
5050

51-
QOBUZ_CREDENTIALS_FILE=/user/config/qobuz.txt
5251
HRA_CREDENTIALS_FILE=/user/config/hra.txt
5352

5453
UPMPDCLI_ADDITIONAL_FILE=/user/config/upmpdcli-additional.txt
@@ -78,16 +77,6 @@ if [[ -n $ENABLE_UPRCL ]]; then
7877
fi
7978
fi
8079

81-
if [[ -f "$QOBUZ_CREDENTIALS_FILE" ]]; then
82-
echo "Reading $QOBUZ_CREDENTIALS_FILE"
83-
read_file $QOBUZ_CREDENTIALS_FILE
84-
QOBUZ_USERNAME=$(get_value "QOBUZ_USERNAME" $PARAMETER_PRIORITY)
85-
QOBUZ_PASSWORD=$(get_value "QOBUZ_PASSWORD" $PARAMETER_PRIORITY)
86-
QOBUZ_FORMAT_ID=$(get_value "QOBUZ_FORMAT_ID" $PARAMETER_PRIORITY)
87-
else
88-
echo "File $QOBUZ_CREDENTIALS_FILE not found."
89-
fi
90-
9180
if [[ -f "$HRA_CREDENTIALS_FILE" ]]; then
9281
echo "Reading $HRA_CREDENTIALS_FILE"
9382
read_file $HRA_CREDENTIALS_FILE
@@ -580,11 +569,15 @@ fi
580569
echo "Qobuz Enable [$QOBUZ_ENABLE]"
581570
if [[ "${QOBUZ_ENABLE^^}" == "YES" ]]; then
582571
echo "Processing Qobuz settings";
572+
# creating bogus user to activate the qobuz media server
573+
echo "# qobuzuser is set to an arbitrary value" >> $CONFIG_FILE
574+
echo "# Such value has nothing to do with your username" >> $CONFIG_FILE
575+
echo "# It is just needed to activate the qobuz media server" >> $CONFIG_FILE
576+
echo "# You will need to authenticate using the qobuz-init-auth.py script" >> $CONFIG_FILE
577+
echo "qobuzuser = qobuz" >> $CONFIG_FILE
583578
if [[ -n "${QOBUZ_TITLE}" ]]; then
584579
echo "qobuztitle = ${QOBUZ_TITLE}" >> $CONFIG_FILE
585580
fi
586-
echo "qobuzuser = $QOBUZ_USERNAME" >> $CONFIG_FILE
587-
echo "qobuzpass = $QOBUZ_PASSWORD" >> $CONFIG_FILE
588581
if [[ -n "${QOBUZ_FORMAT_ID}" ]]; then
589582
echo "qobuzformatid = $QOBUZ_FORMAT_ID" >> $CONFIG_FILE
590583
fi

doc/change-history.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
Change Date|Major Changes
44
---|---
5+
2026-05-09|Changes for new qobuz authentication method (see [#670](https://github.com/GioF71/upmpdcli-docker/issues/670))
56
2026-05-04|Fix a bad substitution (see [#668](https://github.com/GioF71/upmpdcli-docker/issues/668))
67
2026-05-04|Submodule `master` updated to Subsonic Plugin 0.9.14
78
2026-05-04|Submodule `edge` updated to Subsonic Plugin 0.9.14

doc/example-configurations.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -265,18 +265,18 @@ services:
265265
- QOBUZ_ENABLE=yes
266266
volumes:
267267
- ./config/uprclconfdir:/uprcl/confdir
268-
- ./config/credentials/qobuz.txt:/user/config/qobuz.txt:ro
269268
labels:
270269
- com.centurylinklabs.watchtower.enable=false
271270
restart: unless-stopped
272271
```
273272

274-
The `qobuz.txt` file should resemble the following:
273+
You will need to authenticate with qobuz. Assuming the service in compose file is named `upmpdcli` as in the previous example file, do the following:
275274

276275
```text
277-
QOBUZ_USERNAME=qobuz-username
278-
QOBUZ_PASSWORD=qobuz-password
279-
QOBUZ_FORMAT_ID=27
276+
# enter the container
277+
docker compose exec upmpdcli /bin/bash
278+
# cd to the qobuz plugin directory
279+
cd /usr/share/upmpdcli/cdplugins/qobuz
280+
# initiate the authentication (follow on-screen instructions)
281+
./qobuz-init-oauth.py
280282
```
281-
282-
Alternatively, those values can be passed as individual environment variables.

0 commit comments

Comments
 (0)