Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Sample Node.js project showing how to scale horizontally with Docker

License

NotificationsYou must be signed in to change notification settings

Maximization/scaling-nodejs-with-docker

Repository files navigation

This project shows how to scale a Node.js application with Docker Compose and use multiple CPU cores. It's similar to cluster mode in PM2, but with a few fundemantal differences. Read more in the accompanying article —From PM2 to Docker: Cluster Mode.

Getting started

  1. Clone this repositorygit clone https://github.com/Maximization/scaling-nodejs-with-docker.git && cd scaling-nodejs-with-docker

  2. Start the application stack scaled to four app instancesdocker-compose up -d --scale app=4

  3. Visithttp://localhost in your browser

  4. Hit refresh and you will see sequential responses from each application instance

About

Sample Node.js project showing how to scale horizontally with Docker

Topics

Resources

License

Stars

Watchers

Forks


[8]ページ先頭

©2009-2025 Movatter.jp