Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ipfs deployment #21

Open
mveytsman opened this issue Oct 31, 2017 · 6 comments
Open

ipfs deployment #21

mveytsman opened this issue Oct 31, 2017 · 6 comments
Assignees

Comments

@mveytsman
Copy link
Contributor

Here's what I was expecting to do:

  1. Create a shared ipfs key (there's one in keybase now called ketherkey)
  2. On deploy run ipfs add thousandetherhomepage.github.io -> this returns a hash
  3. run ipfs name publish --key=ketherkey /ipfs/<HASH> this fixes to a for ketherkey which is constant
  4. Set a DNS TXT record of /ipns/<PeerID>
  5. Now we're available at /ipfs/<HASH> (only this version) or /ipns/<PeerID> (immutable name) or /ipns/thousandetherhomepage.com (immutable name)

This should work in theory, but it looks like ipns is pretty slow on resolution based on my testing. The PeerID for the ketherkey isQmPNsQkxFh5zp6CaGDTp1EhZzhH6Tre6Bdt12ZrY7M8q4k and you'll see that https://gateway.ipfs.io/ipns/QmPNsQkxFh5zp6CaGDTp1EhZzhH6Tre6Bdt12ZrY7M8q4k is much slower than https://gateway.ipfs.io/ipfs/QmbmyPwSTn4XZQnc2GJ6WxfQQXVCQcT74tCeZWRjbNNWL5/

This appears to be a known issue, i.e. see ipfs/kubo#3860 (comment)

One thing we can do is skip ipns and just use the DNS. If we set the TXT record to /ipfs/<HASH>, then /ipns/thousandetherhomepage.com should resolve to the ipfs hash, skipping slow ipns resolution.

The problem is that we would have to update DNS on every deploy to point to the latest version. We can do this manually, or if it's too much effort we can use the Cloudflare API. Unfortunately, Cloudflare doesn't have per-domain keys, so if we're sharing this API key, we'd need to create a new Cloudflare account just for thousandetherhomepage.com and move the domain to it....

What do you think about all of this @shazow

@shazow
Copy link
Contributor

shazow commented Oct 31, 2017

IMO implement it "properly" and let it be slow until IPNS is fixed. Meanwhile we can workaround with publishing the latest hash somewhere and let people access it directly if they want?

@mveytsman
Copy link
Contributor Author

In that case, can you start by setting a TXT record of dnslink=/ipns/QmPNsQkxFh5zp6CaGDTp1EhZzhH6Tre6Bdt12ZrY7M8q4k to thousandetherhomepage.com

@mveytsman
Copy link
Contributor Author

Linking this for future reference https://github.com/ipfs/examples/tree/master/examples/websites

@shazow shazow assigned mveytsman and unassigned shazow Oct 31, 2017
@shazow
Copy link
Contributor

shazow commented Oct 31, 2017

Done.

@mveytsman
Copy link
Contributor Author

@mveytsman
Copy link
Contributor Author

mveytsman commented Oct 31, 2017

TODO

  • Set up node
  • Pin our stuff

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants