{"id":13410529,"url":"https://github.com/PhaserEditor2D/SimpleStaticServer","last_synced_at":"2025-03-14T16:32:17.285Z","repository":{"id":107663783,"uuid":"381924291","full_name":"PhaserEditor2D/SimpleStaticServer","owner":"PhaserEditor2D","description":"A very simple HTTP server for static content (HTML5 games, single page applications).","archived":false,"fork":false,"pushed_at":"2021-07-08T15:01:51.000Z","size":11,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-05-20T03:18:31.769Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/PhaserEditor2D.png","metadata":{"files":{"readme":"README.MD","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2021-07-01T05:50:49.000Z","updated_at":"2024-06-21T16:55:06.227Z","dependencies_parsed_at":null,"dependency_job_id":"c874df3f-4953-4b0e-a0c4-58745223f97e","html_url":"https://github.com/PhaserEditor2D/SimpleStaticServer","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhaserEditor2D%2FSimpleStaticServer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhaserEditor2D%2FSimpleStaticServer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhaserEditor2D%2FSimpleStaticServer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PhaserEditor2D%2FSimpleStaticServer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PhaserEditor2D","download_url":"https://codeload.github.com/PhaserEditor2D/SimpleStaticServer/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243610231,"owners_count":20318929,"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":[],"created_at":"2024-07-30T20:01:07.501Z","updated_at":"2025-03-14T16:32:16.941Z","avatar_url":"https://github.com/PhaserEditor2D.png","language":"Go","funding_links":[],"categories":["Docker"],"sub_categories":["Telegram"],"readme":"# Simple Static Server\n\nThis is a very simple HTTP server for serving static content. For example, for serving HTML5 games and single page applications.\n\n## Download\n\nGet the `SimpleStaticServer` binaries form the [latest release](https://github.com/PhaserEditor2D/SimpleStaticServer/releases).\n\n## Usage\n\nBy default, the server listens at port `1999` and serves the current directory.\nYou can change these values with the arguments:\n\n```\nSimpleStaticServer -port 80 -dir /path/to/public\n```\n\n## Features\n\nThis server has zero configuration (except the `port` and `dir` variables). It servers a single application (probably running in a container).\n\n### Cache control\n\nAll content is cached by the browser (with the exception of the root file -`/index.html`-).\nThis means that all responses include the header:\n\n```\nCache-Control: public, max-age=31104000, immutable\n```\n\nOnly the request to the root file generates a response with the header:\n\n```\nCache-Control: no-store\n```\nThis feature is useful for single page apps built with tools like Webpack. Webpack can generate a different name for a file when the file is modified. So, it is safe to cache every file requested to the server.\n\n### File not found\n\nIf a file is not found, it internally redirects to the `/index.html` file.\nThis is required for single page applications with URL routers running in the browser.\nFor example, Angular apps.\n\n\nThis server is implemented in Go, and uses the `net/http` package.\n\n### Gzip\n\nThe files with these content types are gzip-compressed:\n\n```\ntext/plain\ntext/html\ntext/css\ntext/csv\ntext/javascript\ntext/json\ntext/xml\napplication/json\napplication/xml\napplication/vnd.ms-fontobject\nfont/otf\nfont/ttf\nfont/woff\nfont/woff2\nimage/svg+xml\n```\n\n## Build\n\nJust run the `build.sh` script. It produces the `dist/SimpleStaticServer` binary file.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPhaserEditor2D%2FSimpleStaticServer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FPhaserEditor2D%2FSimpleStaticServer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPhaserEditor2D%2FSimpleStaticServer/lists"}