autorestic
autorestic copied to clipboard
Restic repository not initialized by default in GCP
Describe the bug
When performing initial backup to empty GCP bucket autorestic does not initialize repo on remote. If repo is initialized manually and key
is set in .autorestic.yml
backup works.
Expected behavior
If there is no restic repo autorestic initializes it.
Environment
Version: 1.7.11 - https://hub.docker.com/layers/cupcakearmy/autorestic/latest/images/sha256-7e309931a247a1fa092fe7b83979392f2d174f2c008f6a8000cda723b5cb9d2b
.autorestic.yml
version: 2
locations:
source-data:
from: '/source-data'
to: gcp
options:
backup:
exclude:
- '*/*/aaa/**'
- '*/*/bbb/**'
- '*/*/ccc/**'
backends:
gcp:
type: gs
path: 'some-bucket.example.domain:/'
env:
GOOGLE_PROJECT_ID: 'complicated-string'
GOOGLE_APPLICATION_CREDENTIALS: '/absolute/path/gcp.json'
Execution logs
Using config paths: . /root /root/.config/autorestic
Using config: /root/.config/autorestic/.autorestic.yml
Using lock: /root/.config/autorestic/.autorestic.lock.yml
Backing up location "source-data"
Backend: gcp
> Executing: /usr/bin/restic backup --exclude */*/aaa/** --exclude */*/bbb/** --exclude */*/ccc/** --tag ar:location:source-data /source-data
Fatal: unable to open config file: service.Objects.Get: storage: object doesn't exist
Error: 1 errors were found
Is there a repository at the following location?
gs:some-bucket.example.domain:/
source-data@gcp:
Fatal: unable to open config file: service.Objects.Get: storage: object doesn't exist
Is there a repository at the following location?
gs:some-bucket.example.domain:/
exit status 1