1activegeek / docker-airconnect

AirConnect container for turning Chromecast into Airplay targets
228 stars 27 forks source link

AIRCAST_VAR not usable in docker-compose #14

Closed crixyd closed 4 years ago

crixyd commented 4 years ago

This may simply be an unsupported feature, so close away if that's the case, however I am attempting to run airconnect:latest-arm through docker-compose, and the AIRCAST_VAR environment variable does not accept whitespaces and is therefore unusable.

When using the below docker-compose configuration, I receive the following: ERROR: environment variable name 'AIRCAST_VAR:'-x /config/config.xml'' may not contain whitespace

version: '3' services: airconnect: container_name: airconnect image: 1activegeek/airconnect:latest-arm volumes:

For reference, I have attempted escaping the whitespace with \, however that is sanitised, and I have also attempted simply passing in '-x', however it appears that the 'default' of config.xml file is not read or created.

1activegeek commented 4 years ago

Interesting, have you tried using a " for enclosing your input? I know that whitespace is acceptable, as doing so in a standard docker run command works. I've tried it myself originally. Should have nothing to do with the ARM variant as one point, but should be able to run with whitespace overall. If you can, try using: - AIRCAST_VAR="-x /config/config.xml"

As I write that, I might actually suggest the issue you may be facing is the use of the colon vs the equals sign. As seen in what you input to the issue - you were using the = for your TZ variable but the : for your AIRCAST_VAR variable. A few things to check out and play around with.

crixyd commented 4 years ago

Oh dear, well that is embarrassing! = works beautifully :)

It's funny how many variations I tried, including ", whilst completely overlooking the colon. Thanks very much!

1activegeek commented 4 years ago

All good man, I've been there. Glad I could help out. And glad it got all settled.