Your repository should have Dockerfile in the root directory. Specification of Dockerfile you can find here: https://docs.docker.com/engine/reference/builder/
For Node.JS application it can be something like this:
FROM node:12.10.0
# Create directory where we will place the application
WORKDIR /usr/src/app
# Copy application source code to the image
COPY . .
RUN npm install && \
npm run build
# Which port the application expose
EXPOSE <PORT_EXPOSED_BY_APPLICATION>
# How we will run application
ENTRYPOINT npm run start
Where <PORT_EXPOSED_BY_APPLICATION> is a port which application listen inside container.
To build docker image locally ypou already should have installed docker-daemon on your laptop. How to do it you can find here: https://docs.docker.com/engine/install/
Then you need to go to the root of your repository and run command:
docker build -t test-app:latest .
As result you will have docker image with name test-app and tag latest.
After previous steps you should check docker image. To do this you have to run docker image on your laptop by command:
docker run --rm -pPORT_INSIDE:80 test-app:latest
Where PORT_INSIDE is port from Dockerfile from line EXPOSE.
After running application should be run on http://localhost, so you can open this URL in your browser and check the application. If you see correct web application there you can add this Dockerfile to the repo.