@cryptotaxi247 / kubo / commits / e7989f121

go-ipfs-config: Add correct access control headers to the default api config

License: MIT Signed-off-by: Friedel Ziegelmayer <dignifiedquire@gmail.com>

dignifiedquire committed Nov 20, 2015 at 00:28 UTC e7989f12148dad4799c6afe33e7d4344e21871c6
1 file changed +10
config/init.go
+10
@@ -44,6 +44,16 @@ func Init(out io.Writer, nBitsForKeypair int) (*Config, error) {
44 API: "/ip4/127.0.0.1/tcp/5001",
45 Gateway: "/ip4/127.0.0.1/tcp/8080",
46 },
47 + API: API{
48 + HTTPHeaders: map[string][]string{
49 + "Access-Control-Allow-Headers": []string{
50 + "X-Stream-Output, X-Chunked-Output",
51 + },
52 + "Access-Control-Expose-Headers": []string{
53 + "X-Stream-Output, X-Chunked-Output",
54 + },
55 + },
56 + },
57
58 Bootstrap: BootstrapPeerStrings(bootstrapPeers),
59 SupernodeRouting: *snr,