diff options
| author | Joey Hess <joey@kitenet.net> | 2014-04-10 00:29:47 -0400 |
|---|---|---|
| committer | Joey Hess <joey@kitenet.net> | 2014-04-10 00:29:47 -0400 |
| commit | 68028803bac71f226e03902cfdb033bb1fb2dcc9 (patch) | |
| tree | 59342795c4e3774a61077658a368aab47a9ea65a /Propellor | |
| parent | 1687f4d771c9be7e1f11d34c0f1f274aef4a927c (diff) | |
propellor spin
Diffstat (limited to 'Propellor')
| -rw-r--r-- | Propellor/Property/Apt.hs | 11 | ||||
| -rw-r--r-- | Propellor/Types.hs | 2 |
2 files changed, 11 insertions, 2 deletions
diff --git a/Propellor/Property/Apt.hs b/Propellor/Property/Apt.hs index ff9b3de9..937d1404 100644 --- a/Propellor/Property/Apt.hs +++ b/Propellor/Property/Apt.hs @@ -47,13 +47,22 @@ debCdn = binandsrc "http://cdn.debian.net/debian" kernelOrg :: DebianSuite -> [Line] kernelOrg = binandsrc "http://mirrors.kernel.org/debian" +-- | Only available for Stable and Testing +securityUpdates :: DebianSuite -> [Line] +securityUpdates suite + | suite == Stable || suite == Testing = + let l = "deb http://security.debian.org/ " ++ showSuite suite ++ "/updates " ++ unwords stdSections + in [l, srcLine l] + | otherwise = [] + -- | Makes sources.list have a standard content using the mirror CDN, -- with a particular DebianSuite. -- -- Since the CDN is sometimes unreliable, also adds backup lines using -- kernel.org. stdSourcesList :: DebianSuite -> Property -stdSourcesList suite = setSourcesList (debCdn suite ++ kernelOrg suite) +stdSourcesList suite = setSourcesList + (debCdn suite ++ kernelOrg suite ++ securityUpdates suite) `describe` ("standard sources.list for " ++ show suite) setSourcesList :: [Line] -> Property diff --git a/Propellor/Types.hs b/Propellor/Types.hs index 856e0ea9..c6be30c4 100644 --- a/Propellor/Types.hs +++ b/Propellor/Types.hs @@ -63,7 +63,7 @@ data Distribution deriving (Show) data DebianSuite = Experimental | Unstable | Testing | Stable | DebianRelease Release - deriving (Show) + deriving (Show, Eq) type Release = String |
