Skip to content

Commit

Permalink
fix podman command
Browse files Browse the repository at this point in the history
  • Loading branch information
yylyyl committed Oct 19, 2023
1 parent a85c283 commit 06212e9
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion badges/coverage.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 4 additions & 2 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions src/podman.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ class Podman {
image,
cmds
) {
const args = ['-d', '--name', name]
const args = ['run', '-d', '--name', name]

for (const dev of devices) {
args.push('--device', dev)
}
for (const v of volumes) {
args.push('--v', v)
args.push('-v', v)
}
if (user) {
args.push('--user', user)
Expand Down Expand Up @@ -292,6 +292,7 @@ class PodmanInPodman {
async function createPodmanInPodman(podman, githubWorkdir, workdir, image) {
const tmpDir = await tempDir()

core.startGroup(`✨ [PodmanInPodman] Creating podman-in-podman container...`)
const podmanContainer = await podman.runDetachedContainer(
'podmaninpodman',
['/dev/fuse:rw'],
Expand All @@ -301,6 +302,7 @@ async function createPodmanInPodman(podman, githubWorkdir, workdir, image) {
image,
sleepCmd
)
core.endGroup()

return new PodmanInPodman(podman, podmanContainer)
}
Expand Down

0 comments on commit 06212e9

Please sign in to comment.