mirror of
https://github.com/cupcakearmy/autorestic.git
synced 2024-12-23 16:56:25 +00:00
Compare commits
4 Commits
9bb80f92ca
...
60ae7266d3
Author | SHA1 | Date | |
---|---|---|---|
|
60ae7266d3 | ||
b5604b8b9f | |||
|
24220f6b62 | ||
|
d332f4476b |
4
.github/workflows/build.yml
vendored
4
.github/workflows/build.yml
vendored
@ -3,7 +3,7 @@ name: Main
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
tags:
|
tags:
|
||||||
- "v*.*.*"
|
- 'v*.*.*'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
docker:
|
docker:
|
||||||
@ -40,7 +40,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- uses: actions/setup-go@v3
|
- uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: "^1.20"
|
go-version: '^1.21'
|
||||||
- name: Build
|
- name: Build
|
||||||
run: go run build/build.go
|
run: go run build/build.go
|
||||||
- name: Release
|
- name: Release
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
FROM golang:1.20-alpine as builder
|
FROM golang:1.21-alpine as builder
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY go.* .
|
COPY go.* .
|
||||||
@ -6,7 +6,7 @@ RUN go mod download
|
|||||||
COPY . .
|
COPY . .
|
||||||
RUN go build
|
RUN go build
|
||||||
|
|
||||||
FROM restic/restic:0.16.0
|
FROM restic/restic:0.16.4
|
||||||
RUN apk add --no-cache rclone bash curl
|
RUN apk add --no-cache rclone bash curl
|
||||||
COPY --from=builder /app/autorestic /usr/bin/autorestic
|
COPY --from=builder /app/autorestic /usr/bin/autorestic
|
||||||
ENTRYPOINT []
|
ENTRYPOINT []
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
autorestic forget [-l, --location] [-a, --all] [--dry-run] [--prune]
|
autorestic forget [-l, --location] [-a, --all] [--dry-run] [--prune]
|
||||||
```
|
```
|
||||||
|
|
||||||
This will prune and remove old data form the backends according to the [keep policy you have specified for the location](/location/forget).
|
This will prune and remove old data form the backends according to the [keep policy you have specified for the location](/location/options/forget).
|
||||||
|
|
||||||
The `--dry-run` flag will do a dry run showing what would have been deleted, but won't touch the actual data.
|
The `--dry-run` flag will do a dry run showing what would have been deleted, but won't touch the actual data.
|
||||||
|
|
||||||
|
@ -34,7 +34,7 @@ Then paste this at the bottom of the file and save it. Note that in this specifi
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
# This is required, as it otherwise cannot find restic as a command.
|
# This is required, as it otherwise cannot find restic as a command.
|
||||||
PATH="/usr/local/bin:/usr/bin:/bin"
|
PATH="/usr/local/bin:$PATH"
|
||||||
|
|
||||||
# Example running every 5 minutes
|
# Example running every 5 minutes
|
||||||
*/5 * * * * autorestic -c /path/to/my/.autorestic.yml --ci cron
|
*/5 * * * * autorestic -c /path/to/my/.autorestic.yml --ci cron
|
||||||
|
2
go.mod
2
go.mod
@ -1,6 +1,6 @@
|
|||||||
module github.com/cupcakearmy/autorestic
|
module github.com/cupcakearmy/autorestic
|
||||||
|
|
||||||
go 1.20
|
go 1.21
|
||||||
|
|
||||||
require (
|
require (
|
||||||
github.com/blang/semver/v4 v4.0.0
|
github.com/blang/semver/v4 v4.0.0
|
||||||
|
@ -17,7 +17,7 @@ import (
|
|||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
)
|
)
|
||||||
|
|
||||||
const VERSION = "1.7.10"
|
const VERSION = "1.7.11"
|
||||||
|
|
||||||
type OptionMap map[string][]interface{}
|
type OptionMap map[string][]interface{}
|
||||||
type Options map[string]OptionMap
|
type Options map[string]OptionMap
|
||||||
|
2
main.go
2
main.go
@ -5,7 +5,7 @@ Licensed under the Apache License, Version 2.0 (the "License");
|
|||||||
you may not use this file except in compliance with the License.
|
you may not use this file except in compliance with the License.
|
||||||
You may obtain a copy of the License at
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
http://www.apache.org/licenses/LICENSE-2.0
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
Unless required by applicable law or agreed to in writing, software
|
Unless required by applicable law or agreed to in writing, software
|
||||||
distributed under the License is distributed on an "AS IS" BASIS,
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
Loading…
Reference in New Issue
Block a user