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

Discuss the interface #1

Open
mmalecki opened this issue Dec 17, 2013 · 4 comments
Open

Discuss the interface #1

mmalecki opened this issue Dec 17, 2013 · 4 comments

Comments

@mmalecki
Copy link
Contributor

+@kenperkins @indexzero

We should discuss what interfaces from pkgcloud to move here.

I'm proposiing to move out all the bootstrapping and provisioning-related interfaces (Bootstrapper) here (and that's essentially what 0.1.0 is).

@kenperkins also suggested that it'd be nice to have ssh, uploadFile, etc. methods on Server model. I think that'd be sweet.

My idea for that would be to allow creating Bootstrapper object with a target server, so:

var bootstrapper = new Bootstrapper({ keys: ..., server: server });
bootstrapper.bootstrap(...);

This way we avoid putting SSH-related stuff in pkgcloud.

@kenperkins
Copy link
Member

Can you help me understand the use case of Bootstrapper?

@mmalecki
Copy link
Contributor Author

mmalecki commented Jan 3, 2014

So the use case of bootstrapper is creating servers with certain abilities for bootstrapping them. Bootstrapper is able to upload files to a created server and run scripts on it.

So, an example use case would be writing a deployer.

@mmalecki
Copy link
Contributor Author

mmalecki commented Jan 3, 2014

As for why you'd use it, let's say that you want to make a server with Nginx on it. What you'd do is (pseudo-code):

var bootstrapper = new Bootstrapper({ compute: ... );
bootstrapper.createServer({
  image: 'ubuntu',
  flavor: '512mb',
  commands: ['apt-get install -y nginx']
});

@kenperkins
Copy link
Member

Ok, that sheds a little light. Obviously you'd have to be more specific with flavor, image, etc, but the commands certainly make sense.

Given that, yes, that does seem external to pkgcloud proper.

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