Skip to content

Commit ec99363

Browse files
authored
Merge pull request #1 from arushi09-hub/readme
README: Updated readme with deployment steps through devtron
2 parents 9c5157f + ae3bd18 commit ec99363

File tree

7 files changed

+56
-102
lines changed

7 files changed

+56
-102
lines changed

.DS_Store

6 KB
Binary file not shown.

README.md

Lines changed: 56 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,14 @@
66
This application uses the `node` container obtained from the [Docker Hub](https://hub.docker.com/_/node/)
77

88
## Setup
9-
lone this repo and cd into the directory:
9+
Clone this repo and cd into the directory:
1010

1111
```
12-
git clone https://github.com/wercker/getting-started-nodejs.git
12+
git clone https://github.com/devtron-labs/getting-started-nodejs
1313
cd getting-started-nodejs
1414
```
1515

16-
## Running
17-
You can run the sample app in a couple of different ways. The first is to simply launch the executable:
16+
You can run the sample app while executing this command -
1817
```
1918
node app.js
2019
```
@@ -39,6 +38,59 @@ and then refresh your browser pointing to `http://localhost:8080` to see:
3938
{"cities":["Amsterdam","Berlin","New York","San Francisco","Tokyo","London"]}}
4039
```
4140

41+
## Getting started with deploying application through Devtron
42+
43+
Lets see how to deploy a custom nodejs app through Devtron.
44+
Make sure Global Configurations are successfully saved and validated before deploying your application.
45+
46+
**STEP 1**
47+
Login into your Devtron Dashboard, Go to >> Applications >> Create new App. Give an appropriate name to this App, choose the project in which you want to keep the app, and create it.
48+
49+
**STEP 2**
50+
After creating the app, setup the configurations. Copy the repo URL https://github.com/devtron-labs/getting-started-nodejs and paste it the Git repo section of your App. Click save and move to next config.
51+
52+
**STEP 3**
53+
Now choose your Docker build config, the repository where you want to keep your CI build image. Select the container registry from the drop-down.
54+
55+
**STEP 4**
56+
Coming up next is configuring the deployment template. As this is a very simple nodejs application we will be only covering the required the configs.
57+
```
58+
ContainerPort :
59+
port : 8080
60+
servicePort : 80
61+
```
62+
`8080` is the port number on which my nodejs application is running.
63+
64+
Now, select the serviceType, keep it as `LoadBalancer`.
65+
66+
```
67+
service:
68+
type: LoadBalancer
69+
```
70+
71+
**STEP 5**
72+
Now, create a CI/CD workflow for deploying this application. Select the type of pipeline & you can also add “Pre-build” “Post-build” & "Docker build" stages as well. Next add your CD pipeline, by choosing in which environment you want to deploy your app in.
73+
74+
**STEP 6**
75+
You can add or create secrets or configmaps as per your requirement. These values will be automatically mounted with pods and made available as volumes or as env variables as per your selection.
76+
77+
**STEP 7**
78+
That’s it, now trigger your CI pipeline by selecting the latest image and deploy it on your chosen project.
79+
80+
**STEP 8**
81+
After the successful deployment, check out your service manifest for fetching the LoadBalancer URL from the dashboard present in the App Details section.
82+
83+
![](/gifs/fetching_loadbalancer.gif)
84+
85+
**STEP 9**
86+
Use this URL on your browser and you can get the output as.
87+
88+
```
89+
{"cities":["Amsterdam","Berlin","New York","San Francisco","Tokyo"]}
90+
```
91+
92+
Find out a detailed documentation about the configurations from here - https://docs.devtron.ai/devtron/user-guide/creating-application
93+
4294
---
4395
Sign up for Wercker: http://www.wercker.com
4496

azure-pipelines-1.yml

Lines changed: 0 additions & 21 deletions
This file was deleted.

azure-pipelines.yml

Lines changed: 0 additions & 21 deletions
This file was deleted.

devtron-ci.yaml

Lines changed: 0 additions & 56 deletions
This file was deleted.

gifs/.DS_Store

6 KB
Binary file not shown.

gifs/fetching_loadbalancer.gif

6.76 MB
Loading

0 commit comments

Comments
 (0)