Import Backup Script
The bash script "scripts/reload-dump" is throwing errors when it is running on windows. I could make it work by adding quotes around variables and commands where file paths or command names are used to ensure proper handling of spaces. Here are the specific changes I made:
-
Added quotes around the path to the dump file when copying it into the temporary container:
docker cp -L "
{1:-dumps/neo4j-dump-latest.dump}" "
{temp_container}:/dumps/neo4j-dump-latest.dump"
-
Added quotes around the Docker Compose command variable when invoking commands:
"$docker_compose" stop neo4j-1
"$docker_compose" rm -f neo4j-1
-
Added quotes around the service name when bringing up and stopping the Neo4j service:
"$docker_compose" up -d neo4j
"$docker_compose" stop neo4j