Coder Social home page Coder Social logo

jainishshah17 / website Goto Github PK

View Code? Open in Web Editor NEW
1.0 5.0 2.0 11.15 MB

Create, Build, Package and Deploy Sample Portfolio Website using Docker

JavaScript 7.45% CSS 9.89% HTML 81.58% Shell 0.11% Dockerfile 0.98%
docker circleci2 expressjs nodejs portfolio-website circleci docker-registry

website's Introduction

Create, build, package and deploy portfolio website using Express.js, Node.js and Docker (Continuous Integration using CircleCI)

CircleCI

Docker Image

Prerequisites Details

Command to build website locally:

  • Clone source code:
git clone https://github.com/jainishshah17/website.git
  • Install dependencies to build node server for website:
cd website/
## Install bower and bower-art-resolver to install your bower dependencies
npm install -g bower bower-art-resolver
## Install bower dependency packages
bower install
## Install npm dependency packages
npm install
  • Start node server to view website:
npm start

It will look like following ScreenShot: ScreenShot

  • Now its time for you to make changes in code to customise it and make it your portfolio website.

  • Change contents of .hbs files in views directory.

  • Once you are ready just restart you node server and refresh website page http://localhost:3000 in your browser.

Great!!! Now your website is developed locally. Let's follow the next step which is packaging it in Docker image.

Command to build and run docker image locally:

  • Build docker image:
docker build -t jainishshah17/website:latest .
  • Run docker image to test it locally
docker run -d -p 80:80 -p 443:443 -p 3000:3000 jainishshah17/website:latest
## Please login to Docker Registry prior to pushing docker image using `docker login` command
docker push jainishshah17/website:latest
  • Once your docker image if pushed to docker registry. You are ready to Deploy it in prodution.

Deploy docker image in production

There are multiple ways to deploy docker containers. You can choose any cloud provider from Azure, GCP and AWS.

Following are some ways which you can use:

Once you have your container deployed and you have External IP to access now its time to Buy a domain (e.g jainishshah.com) and link it with External IP of your deployed website container. There are multiple website who sells domain names following are couple of them:

I personally prefer the combination of AWS and GoDaddy. Here is the link learn how to point your domain to External IP your deployed website container.

Check out http://jainishshah.com/ to see the example website in action.

website's People

Contributors

jainishshah17 avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.