summaryrefslogtreecommitdiff
path: root/src/Propellor
diff options
context:
space:
mode:
authorJoey Hess2014-06-06 22:46:31 -0400
committerJoey Hess2014-06-06 22:46:31 -0400
commit6fc6d54f8a8b6cff9da2f51dc50d29efbada3d5a (patch)
treeeca324f1aab5da28ec9d930fa144976ca64231cb /src/Propellor
parentfc9fdfe1351dc5273185190af62989caba55ffa8 (diff)
propellor spin
Diffstat (limited to 'src/Propellor')
-rw-r--r--src/Propellor/Property/SiteSpecific/JoeySites.hs11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/Propellor/Property/SiteSpecific/JoeySites.hs b/src/Propellor/Property/SiteSpecific/JoeySites.hs
index b44401ea..c66c167d 100644
--- a/src/Propellor/Property/SiteSpecific/JoeySites.hs
+++ b/src/Propellor/Property/SiteSpecific/JoeySites.hs
@@ -338,3 +338,14 @@ githubBackup = propertyList "github-backup box"
in File.hasPrivContent f
`onChange` File.ownerGroup f "joey" "joey"
]
+
+obnamRepos :: [String] -> Property
+obnamRepos rs = propertyList ("obnam repos for " ++ unwords rs)
+ (mkbase : map mkrepo rs)
+ where
+ mkbase = mkdir "/home/joey/lib"
+ `before` mkdir "/home/joey/backup"
+ mkrepo r = mkdir ("/home/joey/lib/nackup/" ++ r ++ ".obnam")
+ mkdir d = File.dirExists d
+ `before` File.ownerGroup "joey" "joey" d
+