{"id":22962995,"url":"https://github.com/richardcarls/docker-hugo","last_synced_at":"2026-05-11T07:46:26.412Z","repository":{"id":89624030,"uuid":"97179260","full_name":"richardcarls/docker-hugo","owner":"richardcarls","description":"Serve a Hugo site in a Docker container.","archived":false,"fork":false,"pushed_at":"2017-07-16T00:48:18.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-02T03:33:26.492Z","etag":null,"topics":["docker-image","hugo","static-site-generator"],"latest_commit_sha":null,"homepage":null,"language":"Shell","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/richardcarls.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-14T01:22:07.000Z","updated_at":"2017-07-14T01:36:33.000Z","dependencies_parsed_at":null,"dependency_job_id":"946faa2d-f32b-4810-a3dc-cc9c9787dfc7","html_url":"https://github.com/richardcarls/docker-hugo","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/richardcarls/docker-hugo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/richardcarls%2Fdocker-hugo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/richardcarls%2Fdocker-hugo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/richardcarls%2Fdocker-hugo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/richardcarls%2Fdocker-hugo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/richardcarls","download_url":"https://codeload.github.com/richardcarls/docker-hugo/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/richardcarls%2Fdocker-hugo/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263480867,"owners_count":23473164,"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-image","hugo","static-site-generator"],"created_at":"2024-12-14T19:19:22.804Z","updated_at":"2026-05-11T07:46:21.392Z","avatar_url":"https://github.com/richardcarls.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Docker Hugo\n\nServe a Hugo site in a docker container. This image runs Hugo v0.25.1 on Alpine Linux 3.6.\n\n## Usage\n```bash\ndocker run -v /some/hugo/site:/hugo/site -p 1313:1313 richardcarls/hugo\n```\nCreates a user `hugo` with uid matching the mounted site directory and calls `hugo server` to start the built-in web server. It is recommended to define most server arguments in your config file at the site root. See [Configuring Hugo](https://gohugo.io/overview/configuration/) for all configuration options.\n\n### Server\nDue to the behavior of `hugo server`, you will need to specify `HUGO_BASE_URL` when running this image if not running on `localhost`\n```bash\ndocker run -v /some/hugo/site:/hugo/site -e HUGO_BASE_URL=https://myblog.com/ -p 1313:1313 richardcarls/hugo\n```\nSee [https://github.com/gohugoio/hugo/issues/1582]\n\nSpecifying `HUGO_BASE_URL` also causes `--appendPort=false` to be added to the command options. If you need a port to be appended, include it explicitly at the end of `HUGO_BASE_URL`.\n\n### Running other Hugo commands\nSee the [Hugo Command Reference](https://gohugo.io/commands/) for all available commands. It's recommended to use `docker run` to avoid root ownership of generated files.\n\n```bash\n# Create a new Hugo site\ndocker run -it --rm -v /new/hugo/site:/hugo/site richardcarls/hugo new site .\n\n# Create a new post (or whatever)\ndocker run -it --rm -v /new/hugo/site:/hugo/site richardcarls/hugo new post/top-10-floor-cleaning-products\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frichardcarls%2Fdocker-hugo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frichardcarls%2Fdocker-hugo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frichardcarls%2Fdocker-hugo/lists"}