Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

driver: docker-container driver uses --config correctly in rootless mode #2093

Merged
merged 1 commit into from
Nov 13, 2023

Commits on Nov 7, 2023

  1. driver: docker-container driver uses --config correctly in rootless mode

    The `docker-container` driver relies on the default config file location
    for buildkit when writing the configuration file. When run in a rootless
    version of docker (dind), the default location is different.
    
    Instead of trying to figure out where the appropriate default location
    is, this just writes the files to the same location and sets the
    `--config` parameter explicitly. This flag is placed first so a
    user-specified config option in `--buildkitd-flags` will take precedence
    over the implicit config parameter.
    
    This also fixes the `--config` option with the rootless image.
    Previously, the config directory was being copied in a way that rendered
    `/etc` unreadable and the configuration file wasn't readable either. It
    also wasn't copied to the correct place. Now, `--config` is used to
    specify the directory, `/etc` isn't included in the copied archive (so
    the permissions aren't overwritten), and the directory is set as world
    readable to be readable from the rootless buildkit process`.
    
    Signed-off-by: Jonathan A. Sternberg <[email protected]>
    jsternberg committed Nov 7, 2023
    Configuration menu
    Copy the full SHA
    3f42346 View commit details
    Browse the repository at this point in the history