Repository navigation
Fix the Docker command for running the site locally - #1907
Merged
bedroesb merged 1 commit intoNov 5, 2026
Merged
Conversation
The documented Docker command failed with "No repo name found". The
jekyll-github-metadata plugin works out the repository name by running
"git remote" inside the container, where git refuses to read the
bind-mounted repository because it is owned by a different user than
the one in the container ("detected dubious ownership"). This affects
Linux with standard Docker.
- Set "repository: elixir-europe/rdmkit" in _config.yml, so the plugin
no longer needs git. The PAGES_REPO_NWO environment variable used in
CI takes precedence over it, so CI builds are unchanged.
- Drop "chmod -R 777 /srv/jekyll" from the command. It was added for an
older image that ran as a non-root user, and it changed the
permissions of every file in the checkout. The current image runs as
root and does not need it, and the old image can no longer install
the gems in the Gemfile.
- Drop the stray "-w -" argument (jekyll serve watches by default).
- Add a tip for Linux users to run the container as their own user, to
avoid root-owned build output. This is not the default because
$(id -u) does not work in Windows PowerShell/cmd and may not suit
rootless Docker or Podman.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Before approving and merging a pull request (PR), the editors must check that
Please refer to the complete editor's checklist for details. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Docker command on the Working with Git page currently fails with:
jekyll-github-metadataworks out the repository name by runninggit remoteinside the container. The currentjekyll/jekyll:4image runs as root, and git refuses to read the bind-mounted repository owned by the host user ("detected dubious ownership"). This hits Linux with standard Docker. The same error was reported in #1071 but not fixed in what was merged there.Changes
_config.yml: setrepository: elixir-europe/rdmkit, so the plugin no longer needs git. CI is unchanged, becausePAGES_REPO_NWO(set in the workflows) takes precedence over the config value.working_with_git.md:chmod -R 777 /srv/jekyll. It was added in Update working_with_git.md #1071 for an older image that ran as a non-root user, and it changes the permissions of every file in the checkout, sogit statusshows the whole repo as modified. The current image doesn't need it, and the old image can no longer install the gems in the Gemfile anyway.-w -(jekyll servewatches by default).--user $(id -u):$(id -g) -e BUNDLE_PATH=vendor/bundle), to avoid root-owned build output. It's a tip rather than the default because$(id -u)doesn't work in Windows PowerShell or cmd, and may not suit rootless Docker or Podman.Tested (Linux, Docker, current
jekyll/jekyll:4image)PAGES_REPO_NWO, and GitHub links point toelixir-europe/rdmkit.--uservariant from the tip builds too, and all output is owned by the host user.jekyll serveis reachable on http://localhost:4000.Not tested: macOS, Windows, and rootless Docker or Podman.
🤖 Generated with Claude Code