Giter Club home page Giter Club logo

Comments (8)

boredazfcuk avatar boredazfcuk commented on May 27, 2024

Can you check to see if your container has a /tmp/icloudpd/icloudpd_sync_error.log log file?

This should contain any errors that are thrown by the icloudpd application.

Edit: I was seeing the same thing on one of the accounts I sync. I removed/recreated the cookie and it worked OK again after that.

from docker-icloudpd.

gregbert42 avatar gregbert42 commented on May 27, 2024

Thanks. I didnt know about these. Yes it does. Looks like some file permission issue. will look into it simultaneously

check_exit_code download_exit_code icloudpd_check.log icloudpd_check_error.log icloudpd_sync.log icloudpd_sync_error.log
/tmp/icloudpd # cat icloudpd_sync_error.log
Traceback (most recent call last):
File "/usr/bin/icloudpd", line 11, in
load_entry_point('icloudpd==1.4.4', 'console_scripts', 'icloudpd')()
File "/usr/lib/python3.8/site-packages/click-6.7-py3.8.egg/click/core.py", line 722, in call
return self.main(*args, **kwargs)
File "/usr/lib/python3.8/site-packages/click-6.7-py3.8.egg/click/core.py", line 697, in main
rv = self.invoke(ctx)
File "/usr/lib/python3.8/site-packages/click-6.7-py3.8.egg/click/core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/lib/python3.8/site-packages/click-6.7-py3.8.egg/click/core.py", line 535, in invoke
return callback(*args, **kwargs)
File "/usr/lib/python3.8/site-packages/icloudpd-1.4.4-py3.8.egg/icloudpd/base.py", line 238, in main
File "/usr/lib/python3.8/site-packages/icloudpd-1.4.4-py3.8.egg/icloudpd/authentication.py", line 29, in authenticate
File "/usr/lib/python3.8/site-packages/pyicloud_ipd/base.py", line 193, in init
self.authenticate()
File "/usr/lib/python3.8/site-packages/pyicloud_ipd/base.py", line 223, in authenticate
self.session.cookies.save()
File "/usr/lib/python3.8/http/cookiejar.py", line 1890, in save
with open(filename, "w") as f:
PermissionError: [Errno 13] Permission denied: '/config/usernamegmailcom'

from docker-icloudpd.

gregbert42 avatar gregbert42 commented on May 27, 2024

ps. this file has permissions -rw-r--r-- not sure why its trying to write to it??

from docker-icloudpd.

boredazfcuk avatar boredazfcuk commented on May 27, 2024

Pretty sure that's same as what I was seeing... Does the cookie file have the correct owner?

What about the /config directory it lives in?

from docker-icloudpd.

gregbert42 avatar gregbert42 commented on May 27, 2024

remind me what the 'correct' owner is?
ive tried setting the file to 666 to see if that files it.

rw-r--r-- permissions are correct... rw------- should also work, provided you have the correct owner, and would also be more secure... Maybe I'll do that in a future update

from docker-icloudpd.

boredazfcuk avatar boredazfcuk commented on May 27, 2024

Well, my /config directory was owned by root, but I don't think that's correct.

Looking at the function that generates the 2FA cookie, it sets the owner of the /config directory, and any files in it to ${user}:${group}

These will be displayed in the logs as:

Local user: <your user here>
Local group: <your group here>

This means that it only confirms permissions at the point when the cookie is created/updated. I've added the /config directory to the function in the script which sets the owner and permissions at launch. I've also added a chown at the start of the sync, just to make sure.

I'm not sure why that file would suddenly change owner. It may be something on the host that affected it, or something in my launch script that changes it to root, but either way, it should be a bit more reliable now.

I've pushed the latest version of my iCloudPD container to here, which should trigger a DockerHub build... But my script which pushes to GitHub also pushes the latest versions of all my containers. DockeHub can take quite a while to build them all, so depending on the order it processes them, it could be a few hours before you can just docker pull boredazfcuk/icloudpd to get the new version.

Thanks.

from docker-icloudpd.

gregbert42 avatar gregbert42 commented on May 27, 2024

Changing the permissions worked. And i think when i converted to the new update, i didnt change the ownership of the file to reflect the 'user' variable.. thank you

from docker-icloudpd.

boredazfcuk avatar boredazfcuk commented on May 27, 2024

Changing the permissions worked. And i think when i converted to the new update, i didnt change the ownership of the file to reflect the 'user' variable.. thank you

Changing the permissions worked, or the owner?

All but about 3 or 4 command in my script runs as root, so there shouldn't be any permissions issues for the most part.

It does run the sync process as the user specified in the $user variable, but if this account is set as the owner for everything in /config and /home//, then that shouldn't run into permissions errors either.

Are you sure it didn't start working because after you upgraded to the latest version, it set the owner on /config correctly? I've just changed my /config directory permissions to 700 and the file perms to 600 and it's pulled down 5 new photos fine.

from docker-icloudpd.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.