Skip to content

Fix the Docker command for running the site locally - #1907

Merged
bedroesb merged 1 commit into
elixir-europe:masterfrom
carissableker:fix_docker_local_build
Nov 5, 2026
Merged

bedroesb merged 1 commit into
elixir-europe:masterfrom
carissableker:fix_docker_local_build

Conversation

@carissableker

Copy link
Copy Markdown
Contributor

The Docker command on the Working with Git page currently fails with:

Liquid Exception: No repo name found. Specify using PAGES_REPO_NWO environment variables, 'repository' in your configuration, or set up an 'origin' git remote pointing to your github.com repository.

jekyll-github-metadata works out the repository name by running git remote inside the container. The current jekyll/jekyll:4 image 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: set repository: elixir-europe/rdmkit, so the plugin no longer needs git. CI is unchanged, because PAGES_REPO_NWO (set in the workflows) takes precedence over the config value.
  • working_with_git.md:
    • Drop 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, so git status shows 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.
    • Drop the stray -w - (jekyll serve watches by default).
    • Add a tip for Linux users to run the container as their own user (--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:4 image)

  • The documented command builds the full site without PAGES_REPO_NWO, and GitHub links point to elixir-europe/rdmkit.
  • The --user variant from the tip builds too, and all output is owned by the host user.
  • jekyll serve is reachable on http://localhost:4000.

Not tested: macOS, Windows, and rootless Docker or Podman.

🤖 Generated with Claude Code

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>
@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

Before approving and merging a pull request (PR), the editors must check that

  • The page layout in the preview looks correct.
  • The new page is linked in the appropriate sidebar menu, in the same branch of the PR.
  • The contributors' names are listed in the CONTRIBUTORS file, in the same branch of the PR. Advice to have at least one contributor per page having its contact information in this CONTRIBUTORS file.
  • All relevant metadata fields in a specific page are correctly filled in (see the page metadata and the Editorial board guide). Some critical ones are listed below.
    • unique page_id (List of page IDs)
    • contributors
    • editors
    • related_pages (Related pages)
    • training
    • search_exclude must be deleted
    • description
    • supported_by (only used for Tool assembly pages)
    • coordinators(only used in national pages + they must be listed as contributors as well)
    • resources
  • Make sure that listed tools or resources are tagged in the text with the correct snippet + that its metadata is described in the tool_and_resource_list.yml file.
  • Check if relevant recipes on FAIR Cookbook can be linked to the RDMkit page that is being added/changed (Linking from RDMkit to FAIR Cookbook).
  • The content conforms to RDMkit's scope, style and templates.
  • There are no copyright issues related to the content of the page.
  • The contributors implemented the requested changes.
  • When a new page is added, a news item is added to the news.yml file, in the same branch of the PR.
  • The contributors are acknowledged for their efforts and informed about the publication of their content.
  • The PR is linked to related issues and can be merged into the main branch with no conflicts.

Please refer to the complete editor's checklist for details.

@bedroesb bedroesb left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and works, thank!

@bedroesb
bedroesb merged commit d0df349 into elixir-europe:master Nov 5, 2026
5 checks passed
@carissableker
carissableker deleted the fix_docker_local_build branch November 5, 2026 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants