Skip to content
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

Changed the value of the environment variable setting, but the icloudpd.conf is not updated synchronously #308

Closed
Alano-i opened this issue Apr 11, 2023 · 7 comments

Comments

@Alano-i
Copy link
Contributor

Alano-i commented Apr 11, 2023

tag: stable
Changed the value of the environment variable setting, but the icloudpd.conf is not updated synchronously.
After modifying the value of the environment variable, must to modify the value in the .conf file at the same time to take effect.
I don't know if it's just me.
image

@boredazfcuk
Copy link
Owner

This is the expected behaviour. The settings in icloudpd.conf take priority over environment variables.

If the icloudpd.conf file does not exist, it creates a file with default settings, but will also migrate any configured environment variables into the file.

@Alano-i Alano-i closed this as completed Apr 12, 2023
@Alano-i
Copy link
Contributor Author

Alano-i commented Apr 12, 2023

If the configuration is modified in the environment variable, would it be better to update it to the .conf file synchronously?

@Alano-i Alano-i reopened this Apr 12, 2023
@Alano-i
Copy link
Contributor Author

Alano-i commented Apr 12, 2023

In the issue list,
several errors were reported synchronously because the environment variable settings did not take effect due to the default value in icloudpd.conf,or the modification of the environment variable icloudpd.conf file was not updated to the new configuration, resulting in synchronous error reporting.
Can the icloudpd.conf file be updated synchronously?

@boredazfcuk
Copy link
Owner

I have made modifications which should mean that the environment variables now set the values in the icloudpd.conf configuration files,. I've just pushed a new latest container to DockerHub. Can you upgrade and test?

I will be looking to deprecate this capability at some point in the future though, as I really want to move away from configuration via variables.

@Alano-i
Copy link
Contributor Author

Alano-i commented Apr 14, 2023

You're right. There are too many environment variables, and it's troublesome to set them one by one. I have an idea maybe it's a solution?.

List all configuration items in the .conf file and set the default value. if there is any configuration in the environment variable changed, then updated .conf file.

In this way, users can run icloudpd by either configuring the .conf file or setting environment variables.

If don't want to setting environment variables, just modify the .config file.

Hope this can help.

@boredazfcuk
Copy link
Owner

Closing this as it should have been changed last week.

@AlexaAmaya
Copy link

heyy guys, i cant find the icloudpd.conf in my NAS or, it did not created in the right way.:-(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants