DEV Community

Discussion on: Dockerizing modern web apps

Collapse
kr428 profile image
Kristian R.

Though I enjoyed reading through your article, I still wonder why deploying a single-page application requires docker. Isn't that a tad "overkill" for this solution? I mean, after all, a single-page application should be all HTML, CSS and JavaScript files that "just" need to be delivered through some static web server, and I don't even see much special nginx configuration in here. Is the effort of dealing with docker really worth it, in this case? ;)

Collapse
hoverbaum profile image
Hendrik Author

Glad you liked the article and very valid question. If you just look at hosting a website, even if it is a modern web app Docker is not what you would first come up with. Most providers have something dedicated for hosting static websites and they will also handle the SPA redirects to a single html file for you.

But people do come to the point where they want or need to host a website using Docker. This might be because a company wants all deployed artifacts to be of the same making or because for testing environments you only have Docker hosts or an environment to run a Docker container is more easily available to you or you want your backend team to be able to easily run the website on their machines. For all of these cases and more while Docker is not the native solution for hosting websites you might still want to do it this way.