How to edit Flectra source files inside docker container?

I try to edit Flectra template files and I am running it inside docker on macOS. What would be the most effective way to edit the source files on my local machine, f.e. using MS Code?
Thnx!

There are two approaches for this:

  1. Mount the source files from docker to your local machine (-v parameter of docker run, or volumes section in docker-compose.yml)

  2. Run your docker container with openssh enabled. Then when e.g. using PyCharm (best IDE for flectra dev!) use the deployment tool to automatically “upload” changed files into the docker container.

1 Like

I solved it by

docker run -u 0 --env HOST=db_flectra_dev --env USER=flectra --env PASSWORD=flectra -v /Users/_USERNAME_/Documents/folderpath_/_to_/_workspace:/mnt/extra-addons -p 7073:7073 --name flectra_dev --link db_flectra_dev:db_flectra_dev -t flectrahq/flectra

1 Like