Skip to content

Conversation

ArunKumarT1995
Copy link
Contributor

@ArunKumarT1995 ArunKumarT1995 commented Aug 6, 2025

closes #141

Adding Input for runtime-basedir to fix XDG_RUNTIME_DIR needs to be set and writable error.

Updated the docs for the same.

Copy link
Member

@crazy-max crazy-max left a comment

Choose a reason for hiding this comment

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

Thanks for your contrib!

See my comments and also you forgot to run docker buildx bake pre-checkin: https://github.com/docker/setup-docker-action/blob/master/.github/CONTRIBUTING.md#submitting-a-pull-request

When addressed please squash your commits.

yarn.lock Outdated
Comment on lines 1 to 2
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
Copy link
Member

Choose a reason for hiding this comment

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

Seems a tool on your machine updated the yarn lock, please remove these changes.

src/main.ts Outdated
async () => {
const input: context.Inputs = context.getInputs();
const runDir = path.join(os.homedir(), `setup-docker-action-${crypto.randomUUID().slice(0, 8)}`);
const runDir = input.runtimeBasedir || path.join(os.homedir(), `setup-docker-action-${crypto.randomUUID().slice(0, 8)}`);
Copy link
Member

Choose a reason for hiding this comment

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

Need to keep random dir for multiple setup: #141 (comment)

Suggested change
const runDir = input.runtimeBasedir || path.join(os.homedir(), `setup-docker-action-${crypto.randomUUID().slice(0, 8)}`);
const runBasedir = input.runtimeBasedir || path.join(os.homedir(), `setup-docker-action`);
const runDir = path.join(runBasedir, `run-${crypto.randomUUID().slice(0, 8)}`);

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@ArunKumarT1995
Copy link
Contributor Author

sorry let me run bake command and get back.

@crazy-max
Copy link
Member

sorry let me run bake command and get back.

Yes and also squash your commits, thanks!

README.md Outdated
| `rootless` | Bool | `false` | Start daemon in rootless mode |

| `rootless` | Bool | `false` | Start daemon in rootless mode |
| `runtime-basedir` | String | `false` | Docker runtime base directory
Copy link
Member

@crazy-max crazy-max Aug 6, 2025

Choose a reason for hiding this comment

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

Suggested change
| `runtime-basedir` | String | `false` | Docker runtime base directory
| `runtime-basedir` | String | `<home>/setup-docker-action` | Docker runtime base directory

@ArunKumarT1995 ArunKumarT1995 force-pushed the feature/rundirinput branch 2 times, most recently from 8e15b57 to e416dff Compare August 6, 2025 19:08
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
@crazy-max crazy-max force-pushed the feature/rundirinput branch from e416dff to 28ef634 Compare August 6, 2025 19:38
Copy link
Member

@crazy-max crazy-max left a comment

Choose a reason for hiding this comment

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

LGTM thanks

Pushed extra commit to move default to context

Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
@crazy-max crazy-max force-pushed the feature/rundirinput branch from 3105473 to a4da7e5 Compare August 6, 2025 19:43
@crazy-max crazy-max merged commit 74ac62f into docker:master Aug 6, 2025
44 checks passed
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.

Daemon fails to start on runner WSL Ubuntu latest Debian GNU/Linux 10 (buster)
2 participants