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

api-shell make target #1095

Merged
merged 1 commit into from
Jul 22, 2016
Merged

api-shell make target #1095

merged 1 commit into from
Jul 22, 2016

Conversation

smith
Copy link
Contributor

@smith smith commented Jul 22, 2016

make api-shell starts a devshell with redis and the builder-api,
builder-router, builder-sessionsrv, and builder-vault services running.

An api script that can start, stop, and restart these services is
available in the shell.

With this running, along with using the new defaults in
components/builder-web/habitat.conf.sample.js, you can run a local
Builder API service and have the locally running (using Node on your
local machine on port 3000) web app connect to it.

This replaces make start-web-dev and adds Redis to the Dockerfile for
the devshell image.

How is this different than make shell?

make shell can be run multiple times and start multiple dev shells,
which is great if you want to be working on individual components inside the
shell.

I does not expose any ports, because there would be conflicts if you
tried to run more than one instance.

make api-shell exposes port 9636, and is meant to be run once, but you
can still use cargo and everything else that you can in make shell,
so somebody working on the API can make changes, recompile, and run them
while being able to connect to the API service.

How is this different than make start-web-dev?

make start-web-dev ran the Habitat packages for these services, so you
could have a locally running API, but did not give you the ability to
easily make changes to those components. It ran the web app inside the
director, while make api-shell expects you to run the web app locally
on your machine (we should add the ability to run the web app inside a
container at some point, but this functionality is not included here.)

gif-keyboard-7212439022391031913

@smith
Copy link
Contributor Author

smith commented Jul 22, 2016

@thesentinels try

1 similar comment
@smith
Copy link
Contributor Author

smith commented Jul 22, 2016

@thesentinels try

`make api-shell` starts a devshell with redis and the builder-api,
builder-router, builder-sessionsrv, and builder-vault services running.

An `api` script that can start, stop, and restart these services is
available in the shell.

With this running, along with using the new defaults in
components/builder-web/habitat.conf.sample.js, you can run a local
Builder API service and have the locally running (using Node on your
local machine on port 3000) web app connect to it.

This replaces `make start-web-dev` and adds Redis to the Dockerfile for
the devshell image.

*How is this different than `make shell`?*

`make shell` can be run multiple times and start multiple dev shells,
which is great if you want to be working on individual components inside the
shell.

I does not expose any ports, because there would be conflicts if you
tried to run more than one instance.

`make api-shell` exposes port 9636, and is meant to be run once, but you
can still use `cargo` and everything else that you can in `make shell`,
so somebody working on the API can make changes, recompile, and run them
while being able to connect to the API service.

*How is this different than `make start-web-dev`?*

`make start-web-dev` ran the Habitat packages for these services, so you
could have a locally running API, but did not give you the ability to
easily make changes to those components. It ran the web app inside the
director, while `make api-shell` expects you to run the web app locally
on your machine (we should add the ability to run the web app inside a
container at some point, but this functionality is not included here.)

Signed-off-by: Nathan L Smith <[email protected]>
@reset
Copy link
Collaborator

reset commented Jul 22, 2016

@smith looks great! Merge when ready :)

@smith smith merged commit a37acc7 into master Jul 22, 2016
@smith smith deleted the nls/api-shell branch July 22, 2016 17:45
@smith smith removed the In Progress label Jul 22, 2016
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

Successfully merging this pull request may close these issues.

2 participants