Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

restart_process: make compatible with k8s_custom_deploy #393

Merged
merged 3 commits into from
May 3, 2022
Merged

Conversation

landism
Copy link
Member

@landism landism commented May 2, 2022

Problem

#391

The restart_process extension works by setting the docker_build entrypoint arg to point at its restart wrapper script. However, the way k8s_custom_deploy works, docker_build's entrypoint is ignored, which means anyone using restart_process with k8s_custom_deploy would find their processes would not be restarted on update.

Solution

When making the child image for restart_process, also set the docker image's entrypoint itself to the restart wrapper script.
This means k8s_custom_deploy will now work with restart_process unless k8s_custom_deploy returns yaml that sets ContainerSpec.Command. In that case, the process will silently fail to restart and not provide the user any hints.

We still set docker_build's entrypoint. This is sometimes redundant, but needed so that the k8s_yaml that sets ContainerSpec.Command continues to work with this extension.

@landism landism requested review from nicks and milas May 2, 2022 20:46
@landism landism merged commit 2c9758c into master May 3, 2022
@landism landism deleted the matt/391 branch May 3, 2022 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants