jozemario / angular-ssr-docker

Angular SSR with Angular Universal and deploy in Docker

Home Page:angular-ssr-docker.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Angular SSR with Angular Universal and Deploy with Docker

How to run?

  1. Clone the project

  2. Open terminal in the project and start JSON server

    json-server --watch db.json
  3. Open another terminal in same project and run the application

    npm run dev:ssr
    
  4. Go to http://localhost:4200 to browse the application

Deploy with docker

  1. Build the application, use sudo if necessary

      ng build && ng run angular-ssr-docker:server
  2. Build Docker images

      docker build -t angular_ssr_docker .
  3. Run the image

    docker run -p 4000:4000 angular_ssr_docker
  4. Go to http://localhost:4000 to browse the application

About

Angular SSR with Angular Universal and deploy in Docker

angular-ssr-docker.vercel.app


Languages

Language:TypeScript 55.9%Language:HTML 37.1%Language:JavaScript 5.5%Language:SCSS 0.9%Language:Dockerfile 0.6%