Skip to content

How to use Firebase to host IPFS static site?

Tutorial Description

In this tutorial we will be deploying a static site generated via dentropys-obsidian-publisher to Filebase's IPFS hosting service.

You can host a static site you write yourself in HTML or built with a Static Site Generators on IPFS. There are a few caviates such as having to use relative rather than absolute links.

Background Information

How to publish a Obsidian Vault using obsidian-publisher?

How to use Filebase to host a IPFS site?


cd ~/Projects/dentropys-obsidian-publisher/dentropy.github.io/docs

sed -i 's/\.\.\//\.\//g' index.html

cd ..

ipfs add -r docs

CID=QmRD2s9aGr29dpbZrVaMQVkMSdtYH8z5Cjz2m2MfCds5pV


# You may need to wait a minute or two
wget -O root.car \
    http://localhost:8081/ipfs/$CID?format=car

aws configure

aws \
    --endpoint https://s3.filebase.com \
    s3 cp \
    ./root.car \
    s3://ddaemonwiki --metadata 'import=car'

From DentropyCloud Video on Rumble

Testing dentropys-obsidian-publisher on different IPFS hosting providers

dentropys-obsidian-publisher

Where the IPFS static site works:

ipfs://bafybeidlxtv2su22mava5qdwee3lz5xhfxzyychm3bt2d55yhgjanva6k4

https://ipfs.ddaemon.org - Filebase

https://bafybeidlxtv2su22mava5qdwee3lz5xhfxzyychm3bt2d55yhgjanva6k4.ipfs.dweb.link/

Where the IPFS static site fails:

https://cloudflare-ipfs.com/ipfs/QmVbDR3yEfAzByroCPeCSbAakgpi2h4MmKzTDxKsBZ9Nnr/

https://ipfs.eth.aragon.network/ipfs/bafybeidlxtv2su22mava5qdwee3lz5xhfxzyychm3bt2d55yhgjanva6k4/

Sources