mirror of
https://github.com/cupcakearmy/autorestic.git
synced 2025-09-01 08:10:39 +00:00
add support for rest server backends
Backend configuration would be; ``` rest_repo: type: rest path: http://backup:8001/repo_name ``` Would result in the following env var; ``` RESTIC_REPOSITORY=rest:http://backup:8001/repo_name ```
This commit is contained in:
@@ -17,9 +17,8 @@ export const getPathFromBackend = (backend: Backend): string => {
|
||||
case 'gs':
|
||||
case 's3':
|
||||
case 'sftp':
|
||||
return `${backend.type}:${backend.path}`
|
||||
case 'rest':
|
||||
throw new Error(`Unsupported backend type: "${backend.type}"`)
|
||||
return `${backend.type}:${backend.path}`
|
||||
default:
|
||||
throw new Error(`Unknown backend type.`)
|
||||
}
|
||||
|
Reference in New Issue
Block a user