Hello,
I am trying to make an offline copy of my google photo's. Now did i find a post on how to do that and it works fine when i run the .sh scrip in a shell. However if i try to run it as an cron job is fails to run correctly.
the .sh file contains the following,
the cron job looks as follow,
The error message when running the cron job is is the following,
I see that in the line "No such file or directory: '/.config/gphotos-sync/client_secret.json" the is an "/" in front of .config. I think that is incorrect but i can't figure out what is causing that and why it runs fine from within the shell.
does anyone have an idea what is wrong and how i can fix it?
I am running FreeNAS-11.3-U2.1
Thx.
I am trying to make an offline copy of my google photo's. Now did i find a post on how to do that and it works fine when i run the .sh scrip in a shell. However if i try to run it as an cron job is fails to run correctly.
the .sh file contains the following,
Code:
cd /root/gphotos-sync pipenv-3.7 run /root/gphotos-sync/gphotos-sync --db-path=/mnt/photo/_db --logfile=/mnt/photo/_db/gphotos.log --photos-path= /mnt/photo/user/ > /root/photo-user.txt
the cron job looks as follow,
The error message when running the cron job is is the following,
Code:
Traceback (most recent call last): File "/root/gphotos-sync/gphotos/authorize.py", line 44, in __init__ with secrets_file.open("r") as stream: File "/usr/local/lib/python3.7/pathlib.py", line 1203, in open opener=self._opener) File "/usr/local/lib/python3.7/pathlib.py", line 1058, in _opener return self._accessor.open(self, flags, mode) FileNotFoundError: [Errno 2] No such file or directory: '/.config/gphotos-sync/client_secret.json' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/root/gphotos-sync/gphotos/Main.py", line 417, in main self.setup(args, db_path) File "/root/gphotos-sync/gphotos/Main.py", line 282, in setup scope, credentials_file, secret_file, int(args.max_retries) File "/root/gphotos-sync/gphotos/authorize.py", line 58, in __init__ exit(1) File "/.local/share/virtualenvs/gphotos-sync-wbnW4jFe/lib/python3.7/site.py", line 397, in __call__ raise SystemExit(code) SystemExit: 1 04-28 12:09:00 gphotos.Main WARNING Done. 04-28 12:09:00 gphotos.Main INFO Elapsed time = 0:00:00.014519
I see that in the line "No such file or directory: '/.config/gphotos-sync/client_secret.json" the is an "/" in front of .config. I think that is incorrect but i can't figure out what is causing that and why it runs fine from within the shell.
does anyone have an idea what is wrong and how i can fix it?
I am running FreeNAS-11.3-U2.1
Thx.