Closed screwfaze closed 4 years ago
Which changes are you trying to have persist? How are you starting the Docker container... via docker
or docker-compose
?
You can easily persist any changes by mounting the volume to a local path and mapping it to a docker container path.
See: https://docs.docker.com/storage/volumes/ for docker
See: https://docs.docker.com/compose/compose-file/#volume-configuration-reference for docker compose
I was facing the same problem, and could figure out what was happening. Every change you make on the strategies, or any other file you have to push it to the running container. For example, I created a strategy mystrat.js and parameter file mystrat.toml. I push it to the running container with the command:
docker cp strategies/mystrat.js gekko_gekko:/usr/src/app/strategies
docker cp config/strategies/mystrat.toml gekko_gekko:/usr/src/app/config/strategies
This should be called with a running container. Every file you want to update the container you must copy to it.
I was facing the same problem, and could figure out what was happening. Every change you make on the strategies, or any other file you have to push it to the running container. For example, I created a strategy mystrat.js and parameter file mystrat.toml. I push it to the running container with the command:
docker cp strategies/mystrat.js gekko_gekko:/usr/src/app/strategies
docker cp config/strategies/mystrat.toml gekko_gekko:/usr/src/app/config/strategies
This should be called with a running container. Every file you want to update the container you must copy to it.
Interesting, I didn't know you could do that. To be honest I would still recommend using a volume
mount configuration... then you don't need to copy any file. It is instantly updated on save because docket would be referencing the host directory for the given path.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. If you feel this is very a important issue please reach out the maintainer of this project directly via e-mail: gekko at mvr dot me.
Note: this is the technical bug tracker, please use other platforms for getting support and starting a (non technical) discussion. See the getting help page for details.
I'm submitting a ... [x] bug report [ ] question about the decisions made in the repository
Action taken (what you did) Recreating the container
Expected result (what you hoped would happen) Changes do not persist after recreating the Docker contaciner
Actual result (unexpected outcome)
Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, etc)
I am using the Docker build and does not have a way to persist changes after recreating the container. Also would be extremely helpful if it could resume trading after a restart.