{"id":19542225,"url":"https://github.com/pythonzm/docker-nginx","last_synced_at":"2026-02-13T03:10:24.276Z","repository":{"id":96962337,"uuid":"96323027","full_name":"pythonzm/docker-nginx","owner":"pythonzm","description":null,"archived":false,"fork":false,"pushed_at":"2017-07-12T07:33:38.000Z","size":9,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-08T18:49:58.726Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Nginx","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pythonzm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2017-07-05T13:35:36.000Z","updated_at":"2017-07-05T13:45:18.000Z","dependencies_parsed_at":null,"dependency_job_id":"b1adc84d-835c-4ae2-bfcc-3be5b3cbb539","html_url":"https://github.com/pythonzm/docker-nginx","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pythonzm%2Fdocker-nginx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pythonzm%2Fdocker-nginx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pythonzm%2Fdocker-nginx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pythonzm%2Fdocker-nginx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pythonzm","download_url":"https://codeload.github.com/pythonzm/docker-nginx/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240796081,"owners_count":19858950,"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-11-11T03:13:44.526Z","updated_at":"2026-02-13T03:10:24.210Z","avatar_url":"https://github.com/pythonzm.png","language":"Nginx","funding_links":[],"categories":[],"sub_categories":[],"readme":"# docker-nginx\n\n# How to use this image\n\n## Hosting some simple static content\n```\n$ docker run --name some-nginx -v /some/static-html-directory:/usr/share/nginx/html:ro -d nginx\n```\nAlternatively, a simple Dockerfile can be used to generate a new image that includes the necessary content (which is a much cleaner solution than the bind mount above):\n```\nFROM nginx\nCOPY static-html-directory /usr/share/nginx/html\n```\nPlace this file in the same directory as your directory of content (\"static-html-directory\"), run `docker build -t some-content-nginx .`, then start your container:\n```\n$ docker run --name some-nginx -d some-content-nginx\n```\n## Exposing external port\n\n```\n$ docker run --name some-nginx -d -p 8080:80 some-content-nginx\n```\nThen you can hit `http://localhost:8080` or `http://host-ip:8080` in your browser\n\n## Complex configuration\n\n```\n$ docker run --name my-custom-nginx-container -v /host/path/nginx.conf:/etc/nginx/nginx.conf:ro -d nginx\n```\nIf you wish to adapt the default configuration, use something like the following to copy it from a running nginx container:\n```\n$ docker run --name tmp-nginx-container -d nginx\n$ docker cp tmp-nginx-container:/etc/nginx/nginx.conf /host/path/nginx.conf\n$ docker rm -f tmp-nginx-container\n```\nThis can also be accomplished more cleanly using a simple Dockerfile (in /host/path/):\n```\nFROM nginx\nCOPY nginx.conf /etc/nginx/nginx.conf\n```\nIf you add a custom CMD in the Dockerfile, be sure to include -g daemon off; in the CMD in order for nginx to stay in the foreground, so that Docker can track the process properly (otherwise your container will stop immediately after starting)!\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpythonzm%2Fdocker-nginx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpythonzm%2Fdocker-nginx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpythonzm%2Fdocker-nginx/lists"}