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

Running container for development #9

Closed
amirilidan78 opened this issue Feb 18, 2022 · 1 comment
Closed

Running container for development #9

amirilidan78 opened this issue Feb 18, 2022 · 1 comment
Labels
question Further information is requested

Comments

@amirilidan78
Copy link

amirilidan78 commented Feb 18, 2022

Great work ,
Can you tell me how can i run this container for development
i added --watch flag to supervisor command and it throws this error :

==================Error==================
Error: Cannot find module 'chokidar'

Require stack:

- /var/www/html/api/laravel/vendor/laravel/octane/bin/file-watcher.js

    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)

    at Function.Module._load (node:internal/modules/cjs/loader:778:27)

    at Module.require (node:internal/modules/cjs/loader:1005:19)

    at require (node:internal/modules/cjs/helpers:102:18)

    at Object.<anonymous> (/var/www/html/api/laravel/vendor/laravel/octane/bin/file-watcher.js:1:18)

    at Module._compile (node:internal/modules/cjs/loader:1103:14)

    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1155:10)

    at Module.load (node:internal/modules/cjs/loader:981:32)

    at Function.Module._load (node:internal/modules/cjs/loader:822:12)

    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12) {

  code: 'MODULE_NOT_FOUND',

  requireStack: [

    '/var/www/html/api/laravel/vendor/laravel/octane/bin/file-watcher.js'

  ]

}
==================supervisord==================
[program:octane]
process_name=%(program_name)s_%(process_num)02d
command=php /var/www/html/api/laravel/artisan octane:start --server=swoole --host=0.0.0.0 --port=9000 --workers=auto --task-workers=auto --max-requests=500 --watch

I added this code to Dockerfile but it doesnt work

=====================Dockerfile==================
=======================================
========= NODE  for octane --watch ==================
=======================================
RUN apt install -y nodejs
RUN apt install -y npm
RUN npm i -g chokidar

@smortexa
@tiagodevweb

@smortexa smortexa added the question Further information is requested label Feb 18, 2022
@smortexa
Copy link
Member

This dockerfile doesn't support development mode. You can use Laravel Sail. Also, PRs are welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants