icloud-drive-docker: [BUG] Error during 2FA authentification
Describe the bug
After execting the login command given in README.md
docker exec -it icloud /bin/sh -c "icloud --username=xxxx --session-directory=/app/session_data"
The following error shows:
tian@dorm-synology:/volume1/docker/icloud-drive$ sudo docker exec -it icloud /bin/sh -c "icloud --username=testtest@testtest.com --session-directory=/app/session_data"
Enter iCloud password for testest@testtest.com:
Traceback (most recent call last):
File "/app/venv/bin//icloud", line 8, in <module>
sys.exit(main())
File "/app/venv/lib/python3.9/site-packages/icloudpy/cmdline.py", line 207, in main
api = ICloudPyService(
File "/app/venv/lib/python3.9/site-packages/icloudpy/base.py", line 273, in __init__
self.authenticate()
File "/app/venv/lib/python3.9/site-packages/icloudpy/base.py", line 344, in authenticate
self._webservices = self.data["webservices"]
KeyError: 'webservices'
To Reproduce Steps to reproduce the behavior:
- Execute the command above.
- See error
Configuration If applicable, please share the configuration details
docker-compose.yaml:
version: "3.4"
services:
icloud:
image: mandarons/icloud-drive
environment:
- PUID=1026
- GUID=100
env_file:
- /volume1/docker/icloud-drive/.env.icloud
container_name: icloud
restart: unless-stopped
volumes:
- /volume1/docker/icloud-drive/config.yaml:/app/config.yaml
- /volume2/Onedrive/icloud:/app/icloud/drive
- /volume1/docker/icloud-drive/session_data:/app/session_data
config.yaml:
app:
logger:
# level - debug, info (default), warning or error
level: "info"
# log filename icloud.log (default)
filename: "icloud.log"
credentials:
# iCloud drive username
username: "testest@testtest.com"
# Retry login interval - default is 10 minutes
retry_login_interval: 600
# Drive destination
root: "icloud"
smtp:
...
drive:
destination: "drive"
remove_obsolete: false
sync_interval: 300
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 15 (7 by maintainers)
It seems to work, but it still needs to be modified in one place, otherwise it will report the same webservices error.
then modify HOME_ENDPOINT (I don’t know why it hasn’t been modified by sed command)
to
It’s work. Photos are also starting to download。