{"id":27808552,"url":"https://github.com/trugamr/vite-docker-static-web-server","last_synced_at":"2026-04-13T03:04:02.292Z","repository":{"id":240190049,"uuid":"801915040","full_name":"Trugamr/vite-docker-static-web-server","owner":"Trugamr","description":"Dockerize SPAs and serve with \"static-web-server\"","archived":false,"fork":false,"pushed_at":"2024-05-17T07:11:06.000Z","size":101,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-08T17:04:35.872Z","etag":null,"topics":["docker","nginx","react","spa","static-web-server","vite","vue"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Trugamr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-17T07:00:35.000Z","updated_at":"2024-05-17T07:14:03.000Z","dependencies_parsed_at":"2024-05-17T08:40:17.150Z","dependency_job_id":null,"html_url":"https://github.com/Trugamr/vite-docker-static-web-server","commit_stats":null,"previous_names":["trugamr/vite-docker-static-web-server"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Trugamr/vite-docker-static-web-server","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Trugamr%2Fvite-docker-static-web-server","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Trugamr%2Fvite-docker-static-web-server/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Trugamr%2Fvite-docker-static-web-server/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Trugamr%2Fvite-docker-static-web-server/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Trugamr","download_url":"https://codeload.github.com/Trugamr/vite-docker-static-web-server/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Trugamr%2Fvite-docker-static-web-server/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261734040,"owners_count":23201758,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","nginx","react","spa","static-web-server","vite","vue"],"created_at":"2025-05-01T10:52:04.963Z","updated_at":"2026-04-13T03:03:57.274Z","avatar_url":"https://github.com/Trugamr.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Dockerizing SPA using SWS (static-web-server)\n\nThis repository provides a reference on how to create a Docker image for client-side applications built with frameworks like React, Vite, etc. The goal is to create a minimal and efficient Docker image. To achieve this, we use [static-web-server](https://github.com/static-web-server/static-web-server) to serve the final build files, ensuring the image remains small and lean.\n\n\n## Why static-web-server?\n\n`static-web-server` is a fast and efficient web server written in Rust, designed specifically for serving static files. It is chosen for this project because:\n\n* It is fast and lightweight, contributing to a smaller Docker image.\n* It provides useful features out-of-the-box like gzip compression, HTTP/2, and customizable headers.\n\n\n## Steps to create Docker Image\n\n\n\n1. **Clone this repository**\n\n    ```bash\n    git clone https://github.com/Trugamr/vite-docker-static-web-server.git\n    cd vite-docker-static-web-server\n    ```\n\n2. **Build the Docker image**\n\n    ```bash\n    docker build -t vite-docker-static-web-server .\n    ```\n\n3. **Run the Docker container**\n\n    ```bash\n    docker run --rm -p 8080:80 vite-docker-static-web-server\n    ```\n\n    The application will be available at [http://localhost:8080](http://localhost:8080).\n\n## License\n\nThis project is licensed under the MIT License.\n\n---\n\nFor more information on how to use `static-web-server`, refer to the [official documentation](https://static-web-server.net/) or the [GitHub repository](https://github.com/static-web-server/static-web-server).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrugamr%2Fvite-docker-static-web-server","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrugamr%2Fvite-docker-static-web-server","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrugamr%2Fvite-docker-static-web-server/lists"}