libresilient/config.js

38 wiersze
2.1 KiB
JavaScript

/*
* LibResilient config
*
* This is the config for LibResilient as deployed on the https://libresilient.is/ site
*
* When deploying LibResilient on your website you will need to create your own config,
* using this one as a template.
*/
// plugins config
self.LibResilientConfig.plugins = {
'fetch':{},
'cache':{},
'any-of': {
plugins: {
'alt-fetch':{
// configuring the alternate endpoints plugin to use IPNS gateways
//
// NOTICE: we cannot use gateways that use hash directly in the (sub)domain:
// https://github.com/node-fetch/node-fetch/issues/260
endpoints: [
'https://ninetailed.ninja/ipns/QmYGVgGGfD5N4Xcc78CcMJ99dKcH6K6myhd4Uenv5yJwiJ/', // Russia
'https://10.via0.com/ipns/QmYGVgGGfD5N4Xcc78CcMJ99dKcH6K6myhd4Uenv5yJwiJ/', // USA
'https://ipfs.sloppyta.co/ipns/QmYGVgGGfD5N4Xcc78CcMJ99dKcH6K6myhd4Uenv5yJwiJ/', // UK
'https://gateway.temporal.cloud/ipns/QmYGVgGGfD5N4Xcc78CcMJ99dKcH6K6myhd4Uenv5yJwiJ/', // Germany
'https://ipfs.best-practice.se/ipns/QmYGVgGGfD5N4Xcc78CcMJ99dKcH6K6myhd4Uenv5yJwiJ/' // Sweden
]
},
'gun-ipfs': {
gunPubkey: 'WUK5ylwqqgUorceQRa84qfbBFhk7eNRDUoPbGK05SyE.-yohFhTzWPpDT-UDMuKGgemOUrw_cMMYWpy6plILqrg'
}
}
}
}
// we need to explicitly list components we want to see debug messages from
self.LibResilientConfig.loggedComponents = ['service-worker', 'fetch', 'cache', 'any-of', 'alt-fetch', 'gun-ipfs']