Skip to content

Hot reloading is not triggered after upgrading to Docker Desktop #30

@ryan-cahill

Description

@ryan-cahill
  • I have tried with the latest version of Docker Desktop
  • I have tried disabling enabled experimental features
  • I have uploaded Diagnostics
  • Diagnostics ID: 53e86c34-6518-444f-a08a-ca1848b241f7/20220617214149

Expected behavior

Hot reloading works for containers when a volume is shared between the host and the container.

Actual behavior

File changes can be seen between the host and the container as expected, however, no hot reloading occurs in any framework.

Information

  • Linux distro: 22.04 LTS
  • Distro version: Ubuntu
  • Docker Desktop Version: 4.9.1 (81317)

Steps to reproduce the behavior

  1. Clone the repo at https://github.com/ryan-cahill/nuxt-test-app
  2. Navigate to the cloned repo's directory root and run docker build . -t nuxt-reload && docker run -it -p 0.0.0.0:3000:3000 -v $(pwd)/src:/usr/src/app/src --name nuxt-reload nuxt-reload to build and run the Docker container.
  3. On your local machine, modify any vue file in the app, for example src/pages/index.vue.
  4. Run docker exec -it nuxt-reload sh to exec into the container, then when in the container, run cat /usr/src/app/src/pages/index.vue and notice that your file changes have taken effect.
  5. Notice that the app hasn't hot reloaded in either the terminal or in your browser. If for example you just ran the app with npm run dev on your host, the app would hot reload when file changes are made. After installing Docker Desktop for Linux, hot reloading no longer works for any application of mine that I run inside of Docker.
  6. Please let me know if I can provide any more information, tests, context, etc.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions