-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compliments not loading from local file. #3233
Comments
the remotefile contains only everything after the compliments:
json has all text in double quotes there are some good online validators and 'local' file needs to be thru a web server
for example, all the files have to be in the mm folder tree |
I corrected one of the working examples above, bad copy/paste. @sdetweil not sure what you're calling out specifically, sorry if that caused confusion above. The referenced gist works if referenced via URL, but if I instead bring that file local to the container, it doesn't load as expected and instead the default compliments are displayed. I don't think this is a json formatting issue as the same contents are present without modification in the gist as well as the json file presented from local file system. |
you can't use the whole filename from the underlying file system because the web server does load this within the So you have to use a relative path, in this case the remoteFile: "../../compliments.json" should work. |
@khassel That did the trick, and makes sense, thanks! |
My docker compose file has volumes setup as:
I copied
compliments.json
which is straight copy of this compliments file to the modules directory. My config for complements is setup as follows:When ran, the default compliments are shown and not the remoteFile that I've specified above. Here's output of running
docker compose exec -t -i magic-mirror ls /opt/magic_mirror/modules
on the host:When I try two other versions of this configuration, the compliments load as expected:
^^^ Works
^^^ Works
Any idea on what might be going on here, why can't I reference the local file for compliments?
The text was updated successfully, but these errors were encountered: