diff --git a/postBuild b/postBuild new file mode 100644 index 00000000..60147cee --- /dev/null +++ b/postBuild @@ -0,0 +1,7 @@ +#!/bin/bash + +IPFS_VERSION=0.10.0 + +wget https://dist.ipfs.io/go-ipfs/v${IPFS_VERSION}/go-ipfs_v${IPFS_VERSION}_linux-amd64.tar.gz +tar -xvzf go-ipfs_v${IPFS_VERSION}_linux-amd64.tar.gz +rm go-ipfs_v${IPFS_VERSION}_linux-amd64.tar.gz diff --git a/start b/start index 0b6cc357..546bae6f 100644 --- a/start +++ b/start @@ -1,5 +1,15 @@ #!/bin/bash -export IPFSSPEC_GATEWAYS="https://tempgw01.web3.storage https://ipfs.io https://dweb.link https://cloudflare-ipfs.com/" +# make ipfs command available +export PATH=$PATH:$HOME/go-ipfs +# set up local node +ipfs init +# configure peering with known peers +ipfs config --json Peering "`curl -L https://github.com/eurec4a/ipfs_tools/raw/main/peers.json`" + +# start the daemon +ipfs daemon 2>ipfs.log | grep -i -o -m1 'Daemon is ready' & tail -f --pid=$! ipfs.log + +# continue starting the jupyter server exec "$@"