Commits create empty SQL file
ncrmro opened this issue · 4 comments
Summary
When I attempt to commit a migration an empty SQL file is generated.
Steps to reproduce
Check out this repo and run yarn commit the ccurent.sql
file will be emptied and an new empty file 000001.sql
is created.
Expected results
000001.sql
containing the current.sql
Actual results
An empty sql file.
Additional context
Currently running inside of docker compose, whose directions can be found in the README.md
Please try this outside of Docker and see if the issue persists.
Even weirder is this works fine on Docker for Mac, but the original error was happening on my Linux workstation.
Apologies for the false issue, thanks for the work your doing @benjie !
EDIT:
What I had to fix this on Linux Docker is use the Rootless version which is more inline with Docker Desktop on Mac and Windows
https://ncrmro.com/posts/docker-linux-workstation-development
Hi @ncrmro, we use Docker for graphile migrate and haven't experienced this problem. Maybe there's some issue with how you're mounting your native filesystem to docker? We use Docker-Compose for our development environments and have a separate container where we run commands like yarn run graphile-migrate watch/commit
. You can check it out here if this helps. - https://github.com/NeonLaw/codebase/blob/development/docker-compose.yml#L120-L128