This migration is only relevant if you're using a React UI for Admin.
Since the introduction of VSCode devcontainers we were using our own file system polling for the parcel container.
Because parcel (or rather Chokidar) supports polling, the container setup can be simplified.
- Recreate the
.devcontainerfolder or copy it from the template on GitHub - Replace the
parcelcontainer definition in./.devcontainers/docker-compose.ymlwith the newly created - Delete the folder
./.devcontainers/parceland replace it with the newly generated folder of the same name - Rebuild the remote container with the following command in VS Code:
Remote-Containers: Rebuild Container
- Change the
parcelsection of./.devcontainers/docker-compose.ymlto the following (add the environment variableCHOKIDAR_USEPOLLING):
parcel:
container_name: parcel-<YOUR_ADAPTER_NAME>
build: ./parcel
expose:
- 1234
ports:
- "1235:1235"
volumes:
- ..:/workspace:cached
environment:
- CHOKIDAR_USEPOLLING=1- Remove the following two scripts in
./.devcontainers/parcel/run-sync.shsync.sh
- Change
./.devcontainers/parcel/run.shto contain the following:
#!/bin/bash
cd /workspace
echo "Installing all dependencies..."
npm install
npm run watch:parcel- Change
./.devcontainers/parcel/Dockerfileto contain the following:
FROM node:12
RUN mkdir -p /usr/app
COPY *.sh /usr/app/
CMD /bin/bash -c "/usr/app/run.sh"- Rebuild the remote container with the following command in VS Code:
Remote-Containers: Rebuild Container