nextcloud / nextcloud/nextcloudpi

nc-snapshot-auto.sh datadirectory cannot be retrieved during crontab execution

Open
#1,651 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

has-updates
Dominant language
Shell
Stars
2.9k
Forks
318
PR merge metrics
No merged PRs in 30d

Description

I try to configure the nc-snapshot-auto.sh on latest nextcloud pi installation.

Unfortunately its not working. it looks like the DATADIR=$(get_nc_config_value datadirectory) cannot be retrieved during crontab execution. Is there the following line missing?

source /usr/local/etc/library.sh

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading nc-snapshot-auto.sh and the referenced get_nc_config_value usage, then check how its cron execution differs from an interactive shell. Inspect whether /usr/local/etc/library.sh is loaded before DATADIR is retrieved. Done means the scheduled snapshot obtains the data directory successfully on a current NextcloudPi installation.

Written by the indexing model from the issue text.

Assessment

Tech stack
raspberry-pi, shell
Domain
devops
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.