go-ipfs-config: reprovider: add config option to set reprovide interval
License: MIT Signed-off-by: Jeromy <why@ipfs.io>
Jeromy committed
Aug 19, 2016 at 16:47 UTC
f5e4f1861c83b2e24a421b877b7f7c84d5b22a99
3 files changed
+10
config/config.go
+2
@@ -29,6 +29,8 @@ type Config struct {
29
SupernodeRouting SupernodeClientConfig // local node's routing servers (if SupernodeRouting enabled)
30
API API // local node's API settings
31
Swarm SwarmConfig
32
+
33
+ Reprovider Reprovider
34
}
35
36
const (
config/init.go
+3
@@ -68,6 +68,9 @@ func Init(out io.Writer, nBitsForKeypair int) (*Config, error) {
68
"Access-Control-Allow-Headers": []string{"X-Requested-With"},
69
},
70
},
71
+ Reprovider: Reprovider{
72
+ Interval: "12h",
73
+ },
74
}
75
76
return conf, nil
config/reprovider.go
new
+5
@@ -0,0 +1,5 @@
1
+package config
2
+
3
+type Reprovider struct {
4
+ Interval string // Time period to reprovide locally stored objects to the network
5
+}