magento / pwa-studio

šŸ› Development tools to build, optimize and deploy Progressive Web Applications for Magento 2.
https://developer.adobe.com/commerce/pwa-studio/
Open Software License 3.0
1.06k stars 683 forks source link

run docker/run-docker with docker image #4249

Open ljr95 opened 4 months ago

ljr95 commented 4 months ago

Hi, I'm discovering Magento PWA and wanted to know if it was possible to run docker/run-docker with a docker image? Below is an example: docker run -v $PWD:/home/node/app -w /home/node/app node:lts docker/run-docker I like to install as few services as possible on the host.

When I run the command above, I encounter this error:

===========================================================================

-e          Creating SSL/TLS certificate

===========================================================================

yarn install v1.22.19
[1/4] Resolving packages...
success Already up-to-date.
Done in 0.16s.
/home/node/app
node:internal/child_process:1124
    result.error = new ErrnoException(result.error, 'spawnSync ' + options.file);
                   ^

<ref *1> Error: spawnSync sudo ENOENT
    at Object.spawnSync (node:internal/child_process:1124:20)
    at spawnSync (node:child_process:876:24)
    at Object.execFileSync (node:child_process:919:15)
    at Object.run (/home/node/app/docker/node_modules/devcert/dist/utils.js:22:28)
    at LinuxPlatform.deleteProtectedFiles (/home/node/app/docker/node_modules/devcert/dist/platforms/linux.js:99:17)
    at uninstall (/home/node/app/docker/node_modules/devcert/dist/certificate-authority.js:124:25)
    at Object.<anonymous> (/home/node/app/docker/node_modules/devcert/dist/certificate-authority.js:18:9)
    at Generator.next (<anonymous>)
    at /home/node/app/docker/node_modules/tslib/tslib.js:110:75
    at new Promise (<anonymous>) {
  errno: -2,
  code: 'ENOENT',
  syscall: 'spawnSync sudo',
  path: 'sudo',
  spawnargs: [ 'rm', '-rf', '/root/.config/devcert/domains' ],
  error: [Circular *1],
  status: null,
  signal: null,
  output: null,
  pid: 0,
  stdout: null,
  stderr: null
}

Node.js v20.12.1

Thank you in advance for your help

m2-assistant[bot] commented 4 months ago

Hi @ljr95. Thank you for your report. To speed up processing of this issue, make sure that you provided sufficient information. Add a comment to assign the issue: @magento I am working on this


Join Magento Community Engineering Slack and ask your questions in #github channel.

glo85315 commented 4 months ago

Hi All, issue is reproducible in local environment. ![Uploading Screenshot 2024-04-15 at 1.22.09 PM.pngā€¦]()