Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
iml-backup
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IML Open Source
iml-backup
Commits
a6245004
Commit
a6245004
authored
5 years ago
by
Hahn Axel (hahn)
Browse files
Options
Downloads
Patches
Plain Diff
added testfile to check a mounted volume
parent
cc752c65
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
README.md
+2
-2
2 additions, 2 deletions
README.md
jobs/transfer.job.dist
+4
-0
4 additions, 0 deletions
jobs/transfer.job.dist
transfer.sh
+10
-1
10 additions, 1 deletion
transfer.sh
with
16 additions
and
3 deletions
README.md
+
2
−
2
View file @
a6245004
...
@@ -5,8 +5,8 @@ Runs on Linux.
...
@@ -5,8 +5,8 @@ Runs on Linux.
Free software. GNU GPL 3.0.
Free software. GNU GPL 3.0.
Source: https://git-repo.iml.unibe.ch/iml-open-source/iml-backup/
Source:
<
https://git-repo.iml.unibe.ch/iml-open-source/iml-backup/
>
Duplicity: http://duplicity.nongnu.org/
Duplicity:
<
http://duplicity.nongnu.org/
>
## Why ##
## Why ##
...
...
This diff is collapsed.
Click to expand it.
jobs/transfer.job.dist
+
4
−
0
View file @
a6245004
...
@@ -59,6 +59,10 @@ restore-path = /restore
...
@@ -59,6 +59,10 @@ restore-path = /restore
# use local filesystem or mounted device
# use local filesystem or mounted device
# storage = scp://imlbackup@lithium.iml.unibe.ch//netshare/backup/one
# storage = scp://imlbackup@lithium.iml.unibe.ch//netshare/backup/one
# for file:// targets - you can add a test file that must be found
# to detect that a backup volume is mounted
# storage-file = /run/media/username/nas/I_am_mounted.txt
# ssh-privatekey = /opt/imlbackup/client/keys/id_rsa_4_backupserver
# ssh-privatekey = /opt/imlbackup/client/keys/id_rsa_4_backupserver
ssh-privatekey =
ssh-privatekey =
...
...
This diff is collapsed.
Click to expand it.
transfer.sh
+
10
−
1
View file @
a6245004
...
@@ -27,6 +27,7 @@
...
@@ -27,6 +27,7 @@
# 2017-11-17 ah,ds v1.5 check pid of lockfile in process list if process still runs
# 2017-11-17 ah,ds v1.5 check pid of lockfile in process list if process still runs
# 2018-06-19 ah,ds v1.6 replace --exclude with --exclude regexp in custom dirs
# 2018-06-19 ah,ds v1.6 replace --exclude with --exclude regexp in custom dirs
# 2019-06-05 ah,ds v1.7 add custom cache dir
# 2019-06-05 ah,ds v1.7 add custom cache dir
# 2019-09-09 ah,ds v1.8 add testfile on target
# ================================================================================
# ================================================================================
...
@@ -42,6 +43,7 @@
...
@@ -42,6 +43,7 @@
typeset
-i
rc
=
0
typeset
-i
rc
=
0
STORAGE_BASEDIR
=
`
_j_getvar
${
STORAGEFILE
}
"storage"
`
STORAGE_BASEDIR
=
`
_j_getvar
${
STORAGEFILE
}
"storage"
`
STORAGE_TESTFILE
=
`
_j_getvar
${
STORAGEFILE
}
"storage-file"
`
STORAGE_KEEP
=
`
_j_getvar
${
STORAGEFILE
}
"keep"
`
STORAGE_KEEP
=
`
_j_getvar
${
STORAGEFILE
}
"keep"
`
STORAGE_VOLSIZE
=
`
_j_getvar
${
STORAGEFILE
}
"volsize"
`
STORAGE_VOLSIZE
=
`
_j_getvar
${
STORAGEFILE
}
"volsize"
`
...
@@ -53,7 +55,14 @@
...
@@ -53,7 +55,14 @@
color reset
color reset
exit
1
exit
1
fi
fi
if
[
!
-z
$STORAGE_TESTFILE
-a
!
-f
$STORAGE_TESTFILE
]
;
then
color error
echo
ERROR: missing testfile
$STORAGE_TESTFILE
on backup target.
echo
The Backup target disk / NAS is not mounted.
color reset
exit
1
fi
if
[
-z
$STORAGE_KEEP
]
;
then
if
[
-z
$STORAGE_KEEP
]
;
then
color error
color error
echo
ERROR: missing config
for
backup target.
echo
ERROR: missing config
for
backup target.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment