I have a java app that I am running via Docker on AWS via the entrypoint:
ENTRYPOINT ["java","-jar", "-Xmx600m", "/app.jar"]
I am running this on AWS ECS. If the java process dies for whatever reason, will the cotnainer be re-launched?
I have a java app that I am running via Docker on AWS via the entrypoint:
ENTRYPOINT ["java","-jar", "-Xmx600m", "/app.jar"]
I am running this on AWS ECS. If the java process dies for whatever reason, will the cotnainer be re-launched?
2
Answers
Yes, if run as a service then it will be re-launched
If you run this as an ECS Service, then yes, when the container exits, the task will be stopped and a new task will be created with a new instance of the container.
If you run it as a Task, without a Service configuration, then no, ECS will not automatically replace the task.