summaryrefslogtreecommitdiffhomepage
path: root/Servers.hs
blob: bb552b7fbcb0238a678aaca0d0f69368e2be7457 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
{- Copyright 2016 Joey Hess <id@joeyh.name>
 -
 - Licensed under the GNU AGPL version 3 or higher.
 -}

module Servers where

import Types.Server
import Servant.Client

serverUrls :: Server -> [BaseUrl]
serverUrls srv = map go (serverAddress srv)
  where
	go (ServerAddress addr port) = BaseUrl Http addr port ""

networkServers :: [Server]
networkServers =
	[ Server (ServerName "keysafe.joeyh.name")
		[ServerAddress "vzgrspuxbtnlrtup.onion" 4242]
	-- Purism server is not yet deployed, but planned.
	, Server (ServerName "keysafe.puri.sm")
		[]
	-- Unknown yet who will provide this server, but allocate it now
	-- so keysafe can start queuing uploads to it.
	, Server (ServerName "thirdserver")
		[]
	]