fix kubo config #263
2 changed files with 15 additions and 4 deletions
|
@ -15,7 +15,7 @@
|
|||
};
|
||||
API.HTTPHeaders = {
|
||||
Access-Control-Allow-Origin = [
|
||||
"http://bafybeic4gops3d3lyrisqku37uio33nvt6fqxvkxihrwlqsuvf76yln4fm.ipfs.localhost:41876"
|
||||
"http://bafybeiamycmd52xvg6k3nzr6z3n33de6a2teyhquhj4kspdtnvetnkrfim.ipfs.localhost:41876"
|
||||
"http://localhost:3000"
|
||||
"http://127.0.0.1:5001"
|
||||
"https://webui.ipfs.io"
|
||||
|
@ -37,6 +37,16 @@
|
|||
prefix = "s3.datastore";
|
||||
type = "measure";
|
||||
}
|
||||
{
|
||||
child = {
|
||||
compression = "none";
|
||||
path = "datastore";
|
||||
type = "levelds";
|
||||
};
|
||||
mountpoint = "/";
|
||||
prefix = "leveldb.datastore";
|
||||
type = "measure";
|
||||
}
|
||||
];
|
||||
type = "mount";
|
||||
};
|
||||
|
|
|
@ -329,11 +329,12 @@ in {
|
|||
environment.IPFS_PATH = cfg.dataDir;
|
||||
|
||||
preStart = let
|
||||
datastore_spec = pkgs.writeText "datastore_spec" ''{"mounts":[{"bucket":"ipfs","mountpoint":"/"}],"type":"mount"}'';
|
||||
datastore_spec = pkgs.writeText "datastore_spec" ''{"mounts":[{"bucket":"ipfs-chir-rs","mountpoint":"/blocks","region":"ams1","rootDirectory":"/"},{"mountpoint":"/","path":"datastore","type":"levelds"}],"type":"mount"}'';
|
||||
in
|
||||
''
|
||||
mkdir -pv $IPFS_PATH/.ipfs/plugins
|
||||
ln -svf ${pkgs.go-ds-s3}/bin/go-ds-s3-plugin $IPFS_PATH/.ipfs/plugins
|
||||
mkdir -pv $IPFS_PATH/plugins
|
||||
cp ${pkgs.go-ds-s3}/go-ds-s3-plugin $IPFS_PATH/plugins
|
||||
chmod +w $IPFS_PATH/plugins/go-ds-s3-plugin
|
||||
# Update the datastore_spec
|
||||
ln -svf ${datastore_spec} $IPFS_PATH/datastore_spec
|
||||
if [[ ! -f "$IPFS_PATH/config" ]]; then
|
||||
|
|
Loading…
Reference in a new issue