{"id":16019668,"url":"https://github.com/tofran/nginx-with-substitutions-filter-docker","last_synced_at":"2025-03-18T03:31:26.557Z","repository":{"id":41950775,"uuid":"402561225","full_name":"tofran/nginx-with-substitutions-filter-docker","owner":"tofran","description":"🐳 Slim Nginx Docker image with substitutions filter module (ngx_http_sub_module)","archived":false,"fork":false,"pushed_at":"2025-03-01T01:35:38.000Z","size":21,"stargazers_count":5,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-16T16:40:10.081Z","etag":null,"topics":["alpine","docker","nginx","nginx-docker"],"latest_commit_sha":null,"homepage":"https://hub.docker.com/r/tofran/nginx-with-substitutions-filter","language":"Dockerfile","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/tofran.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":"2021-09-02T20:58:25.000Z","updated_at":"2025-03-01T01:35:42.000Z","dependencies_parsed_at":"2024-10-27T17:16:06.860Z","dependency_job_id":"300ce3e5-ab41-43a1-bdf7-0fa57e46424f","html_url":"https://github.com/tofran/nginx-with-substitutions-filter-docker","commit_stats":{"total_commits":13,"total_committers":2,"mean_commits":6.5,"dds":"0.23076923076923073","last_synced_commit":"420379dfe88777d7d71ba2b8d4e9ebee8792add6"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tofran%2Fnginx-with-substitutions-filter-docker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tofran%2Fnginx-with-substitutions-filter-docker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tofran%2Fnginx-with-substitutions-filter-docker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tofran%2Fnginx-with-substitutions-filter-docker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tofran","download_url":"https://codeload.github.com/tofran/nginx-with-substitutions-filter-docker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244150560,"owners_count":20406609,"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":["alpine","docker","nginx","nginx-docker"],"created_at":"2024-10-08T17:05:05.071Z","updated_at":"2025-03-18T03:31:26.552Z","avatar_url":"https://github.com/tofran.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nginx Docker image with substitutions filter module\n\n[![Build and deploy](https://github.com/tofran/nginx-with-substitutions-filter-docker/actions/workflows/build.yaml/badge.svg)](https://github.com/tofran/nginx-with-substitutions-filter-docker/actions/workflows/build.yaml)\n[![Docker Image Size (latest semver)](https://img.shields.io/docker/image-size/tofran/nginx-with-substitutions-filter?sort=semver)][DockerHub]\n[![Docker Pulls](https://img.shields.io/docker/pulls/tofran/nginx-with-substitutions-filter)][DockerHub]\n\nSlim Nginx, multi-arch alpine Docker image with [substitution filter module](http://nginx.org/en/docs/http/ngx_http_sub_module.html).\n\nThe final result is a clean image completely based on the official `nginx:alpine`.\nDoes not contain any compile time junk, the only additions are:\n\n- Dynamic module inserted at `/usr/lib/nginx/modules/ngx_http_subs_filter_module.so`;\n- Importing of the module in `/etc/nginx/nginx.conf` with `load_module`.\n\nAvailable on [DockerHub][DockerHub] and on [GitHub container registry][GHCR]:\n\n```sh\ndocker pull tofran/nginx-with-substitutions-filter\n# or\ndocker pull ghcr.io/tofran/nginx-with-substitutions-filter\n```\n\nThis repo could also be helpful as a recipe for building images with any other dynamic modules, or even as way to extract compiled binaries from them.\n\n[DockerHub]: https://hub.docker.com/r/tofran/nginx-with-substitutions-filter\n[GHCR]: https://github.com/tofran/nginx-with-substitutions-filter-docker/pkgs/container/nginx-with-substitutions-filter\n\n\n## Example usage\n\nCreate the following example configuration `./sample.conf`:\n\n```nginx\nserver {\n    listen 80;\n\n    location / {\n        subs_filter_types text/html text/css text/xml application/javascript;\n        subs_filter \"nginx\" \"replaced\";\n        root /usr/share/nginx/html;\n    }\n}\n```\n\nNow run the image:\n\n```sh\ndocker run -p 8080:80 -v ./sample.conf:/etc/nginx/conf.d/default.conf tofran/nginx-with-substitutions-filter\n```\n\nVisit `http://localhost:8080`:\n\n![screenshot](https://github.com/user-attachments/assets/3ab17364-e517-4562-8727-2cf28b55c850)\n\nThere you go, you now have a nginx running with on-the-fly string replacement.\nHappy replacing!\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftofran%2Fnginx-with-substitutions-filter-docker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftofran%2Fnginx-with-substitutions-filter-docker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftofran%2Fnginx-with-substitutions-filter-docker/lists"}