# Dockerize Travel-Website !

**Steps included:**

1 Make a folder

2 Clone the repo

3 Make dockerfile

4 Build the image

5 Run

6 Test the project

## **Step-1**

In this step, we will first make a separate folder/directory

```bash
 mkdir  project02
 cd  project02
```

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685258490067/70d8732e-8eb1-4984-a4b8-6658bca20089.png align="center")

## **Step-2**

In this step, we will clone the git repo in our local

\*\*\*ps: don't forget to go inside the cloned repo \*\*\*\*

```bash
 git clone  https://github.com/frontendzone/travel-website.git
  cd travel-website
```

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685258596207/e2df327d-f3d3-48e5-a57a-8e22aeb55a4d.png align="center")

### **Step-3**

In this we will try to make a docker file

```bash
vim Dockerfile
```

```bash
FROM node:latest
# Create app directory
WORKDIR /home/gauri/project02/travel-website

# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json are copied
# where available (npm@5+)
COPY package*.json ./

RUN npm install
# If you are building your code for production
# RUN npm ci --only=production

# Bundle app source
COPY . .

EXPOSE 3000
CMD [ "npm", "start" ]
```

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685258871608/8d076017-571d-4e72-b083-e242466d0a3e.png align="center")

### **Step-4**

In this step, we will make an image

```bash
 docker build -t gauriyadav1504/pro02 .
```

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685258962346/5b7dd8e5-5159-4ef6-a6b2-880057b6a20e.png align="center")

### **Step-5**

in this we will run the image

```bash
 docker run -p 3000:3000 -d gauriyadav1504/pro02
```

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685259005024/18eb5ca8-2d5d-4bc4-bb3a-59700aa589fb.png align="center")

### **Step-6**

NOW TEST THE OUTPUT

TADDDAAAAAAA!!!!!!

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685259127867/d271bd0b-84ef-4db5-b5fc-dfe02b8085c9.png align="center")

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685259151701/2807c90b-4141-47c2-9ca0-0a3b0304fd26.png align="center")

![](https://cdn.hashnode.com/res/hashnode/image/upload/v1685259180167/4bf0a33d-6f08-49c8-9283-27f16a3a295b.png align="center")

Thanks

Email:gaurieyadav15402@gmail.com
