-
Notifications
You must be signed in to change notification settings - Fork 3
Codefresh
msushkevich edited this page Mar 5, 2016
·
16 revisions
- [Sign in or sign up to your github account] (https://github.com).
- Fork demo_nodejs_auth project to your github account.
- Sign up or sign in to codefresh account using github.
- From the Codefresh console, click the
SERVICESoption on the left. - Click
ADD SERVICE.

- Select app demo project and then click
NEXT.

- On the tab
Dockerfileclik on theNO, I DON’T HAVE A DOCKERFILEand choose theNode.js.

Three next steps are optional. You can skip them by clicking on the CREATE button during the previous step.
-
Click
NEXT. -
On the tab
Customizeyou can change default Dockerfile and clickNEXT. -
On the tab
Testyou can specify optional bash script. This script will be run to test your code. Then clickCREATE. -
Review the results and click
Close & Build.
-
Click
BUILDSon the left, in the sidebar navigation. -
Click on the rocket icon to launch your newly built image in a container.

- Demo application isn't launched. But don't worry:) Follow the next steps to fix it.

- Click on your avatar in the upper right corner to pull down the menu and go to
ACCOUNT MANAGEMENTto access your account settings.

- Click
INTEGRATIONand activate the docker hub integration. - If you don't have a docker hub account, you can create it from here.
- Then enter your Docker Hub username and password in the fields to docker hub integration with codefresh and click
SAVE.

- Back to
BUILDSon the left, in the sidebar navigation and click on the gear icon for your new Service.

- You will see screen
Pipelines

- Click
Push to Docker Registryand then click Docker Hub and clickSAVE

- Click COMPOSITIONS on the left, in the sidebar navigation click
ADD NEW COMPOSITION.

- Enter name for a new composition and click the
+icon to add a service to the composition. - Select your service from the
Pre-configured serviceoption and clickADD.

- Click the
+icon to add another service to the composition and choosePre-built image. - Type mongo into the field and click
ADD.

- Add a links line with the value of mongo. Your composition will look like the one below:
YOUR_COMPOSITION_NAME:
image: YOUR_DOCKER_HUB_USERNAME/YOUR_DOCKER_HUB_REPO:master
ports:
- 5000
links:
- mongo
mongo:
image: mongo
- Click
SAVEbutton.

- Click the rocket icon to LAUNCH your composition.
- Click on generated link to see demo_nodejs_auth application.
