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

Publish to IPNS from Circle CI #11

Open
wants to merge 12 commits into
base: master
from

Conversation

Projects
None yet
4 participants
@harlantwood
Collaborator

harlantwood commented Dec 8, 2015

When the code for this repo changes, we rebuild the JS bundle on Circle CI, check everything into IPFS, publish to IPNS (always the same peer ID / private key), then request all assets from the gateway.

See test below: I changed the text of the exists column header to (exists) and republished:

screenshot 2015-12-07 23 43 58

@jbenet lots of this should be reusable for autodeploys of the website, and whatever else ... ipfs/website#17 & ipfs/website#75

harlantwood added some commits Dec 8, 2015

Publish latest build to a constant IPFS hash on CI
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
init empty repo
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
add parens
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
use wget
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
wget > tmp dir
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
reinstate bluebird
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
simplify
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
@RichardLitt

This comment has been minimized.

Show comment
Hide comment
@RichardLitt

RichardLitt Dec 8, 2015

Member

Nice!

Member

RichardLitt commented Dec 8, 2015

Nice!

@jbenet

This comment has been minimized.

Show comment
Hide comment
@jbenet

jbenet Dec 9, 2015

Member

This is great! though publishing to IPNS wont work, unless you run CI every few hours. the reason is that IPNS needs to be republished over time.

We'll be changing that to allow other nodes to re-share records-- it's a major protocol issue.

Member

jbenet commented Dec 9, 2015

This is great! though publishing to IPNS wont work, unless you run CI every few hours. the reason is that IPNS needs to be republished over time.

We'll be changing that to allow other nodes to re-share records-- it's a major protocol issue.

@harlantwood

This comment has been minimized.

Show comment
Hide comment
@harlantwood

harlantwood Dec 9, 2015

Collaborator

OK... Options:

  1. Publish to ipns hourly. Maybe by triggering CI, or from a cronjob, eg on heroku or digital ocean
  2. Switch to pushing IPFS hash to dns bridge. This requires having a digital ocean token present, so @lgierth doesn't want to have it run from CI. Perhaps it could run from one of our digital ocean servers.
Collaborator

harlantwood commented Dec 9, 2015

OK... Options:

  1. Publish to ipns hourly. Maybe by triggering CI, or from a cronjob, eg on heroku or digital ocean
  2. Switch to pushing IPFS hash to dns bridge. This requires having a digital ocean token present, so @lgierth doesn't want to have it run from CI. Perhaps it could run from one of our digital ocean servers.
@harlantwood

This comment has been minimized.

Show comment
Hide comment
@harlantwood

harlantwood Dec 10, 2015

Collaborator

@lgierth and @jbenet do you have preferences between options 1 & 2 above?

Collaborator

harlantwood commented Dec 10, 2015

@lgierth and @jbenet do you have preferences between options 1 & 2 above?

@lgierth

This comment has been minimized.

Show comment
Hide comment
@lgierth

lgierth Dec 10, 2015

Member

Publish to ipns hourly. Maybe by triggering CI, or from a cronjob, eg on heroku or digital ocean

mh shouldn't the republisher take care of that? @whyrusleeping

Member

lgierth commented Dec 10, 2015

Publish to ipns hourly. Maybe by triggering CI, or from a cronjob, eg on heroku or digital ocean

mh shouldn't the republisher take care of that? @whyrusleeping

@lgierth

This comment has been minimized.

Show comment
Hide comment
@lgierth

lgierth Dec 10, 2015

Member

mh shouldn't the republisher take care of that? @whyrusleeping

ooh, the publishing daemon is ephemeral, within circleci. tricky.

Member

lgierth commented Dec 10, 2015

mh shouldn't the republisher take care of that? @whyrusleeping

ooh, the publishing daemon is ephemeral, within circleci. tricky.

@jbenet

This comment has been minimized.

Show comment
Hide comment
@jbenet

jbenet Dec 10, 2015

Member

@harlantwood both SGTM. if we do a service we host, then:

  • CI could hit a service with the ipfs-path, and it could publish to ipns
  • forget CI, and a webhook could hit a service directly who does all the work. (ci is fine with me)
Member

jbenet commented Dec 10, 2015

@harlantwood both SGTM. if we do a service we host, then:

  • CI could hit a service with the ipfs-path, and it could publish to ipns
  • forget CI, and a webhook could hit a service directly who does all the work. (ci is fine with me)

harlantwood added some commits Dec 13, 2015

fetch from local and gateway servers;
improve shell execution & wget options

License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
use "run" from lightsaber
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>

harlantwood added some commits Dec 15, 2015

only kill if we have a PID
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
minor fix
License: MIT
Signed-off-by: Harlan T Wood <code+harlan@harlantwood.net>
@harlantwood

This comment has been minimized.

Show comment
Hide comment
@harlantwood

harlantwood Dec 30, 2015

Collaborator

I'm going to leave this PR open for now, in hopes that this will change:

@jbenet said in #11 (comment):
publishing to IPNS wont work, unless you run CI every few hours. the reason is that IPNS needs to be republished over time.
We'll be changing that to allow other nodes to re-share records-- it's a major protocol issue.

Collaborator

harlantwood commented Dec 30, 2015

I'm going to leave this PR open for now, in hopes that this will change:

@jbenet said in #11 (comment):
publishing to IPNS wont work, unless you run CI every few hours. the reason is that IPNS needs to be republished over time.
We'll be changing that to allow other nodes to re-share records-- it's a major protocol issue.

@RichardLitt

This comment has been minimized.

Show comment
Hide comment
@RichardLitt

RichardLitt Jul 29, 2016

Member

@lgierth When do we think that will change, for IPNS? Is that in the roadmap?

Member

RichardLitt commented Jul 29, 2016

@lgierth When do we think that will change, for IPNS? Is that in the roadmap?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment