astro icon indicating copy to clipboard operation
astro copied to clipboard

Astro does not refresh with Docker

Open SaulR07 opened this issue 3 years ago • 1 comments

What version of astro are you using?

1.2.6

Are you using an SSR adapter? If so, which one?

None

What package manager are you using?

npm

What operating system are you using?

Windows

Describe the Bug

I create my astro image in docker

FROM node:18-alpine3.15
RUN mkdir app
WORKDIR /app
COPY . .
RUN npm install
EXPOSE 3000
CMD ["npm","run","dev","--","--host"]

I build my image with the following command

docker build . -t astro-image

I run my container with this command

docker run --name astro-container -p 3000:3000 -v C:\Workspace\Docker\docker-astro:/app -v /app/node_modules/ astro-image

So far without problems but when I make a change in the index.astro it does not refresh the page.

But the index.astro inside the container does change.

Link to Minimal Reproducible Example

https://github.com/SaulR07/docker-astro-example

Participation

  • [ ] I am willing to submit a pull request for this issue.

SaulR07 avatar Sep 17 '22 03:09 SaulR07