Sitelet https://web.archive.org/web/20201117230424/https://github.com/devspace-cloud/devspace/issues/1122
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

Better entrypoint override for interactive mode #1122

Open
ralfthewise opened this issue Jun 21, 2020 · 2 comments
Open

Better entrypoint override for interactive mode #1122

ralfthewise opened this issue Jun 21, 2020 · 2 comments

Comments

@ralfthewise
Copy link

@ralfthewise ralfthewise commented Jun 21, 2020 •

Is your feature request related to a problem?
It's related to slow redeployments around interactive mode.

Which solution do you suggest?
When running devspace dev -i the entrypoint override could be something like this:

      interactive:
        images:
          - name: frontend
            entrypoint:
              - sh
            cmd:
              - -c
              - "trap 'exit 1' TERM; sleep 999999999 & wait"

Which alternative solutions exist?
Manually provide the interactive config I pasted in the previous section.

Additional context
Doing sleep 999999999 as the entrypoint takes a long time for the pod to terminate, because sleep doesn't handle SIGTERM - https://superuser.com/a/1299463/157978

As is I just wait 10+ seconds for the pod to terminate before the new one is launched:

$ kubectl get all
NAME                            READY   STATUS        RESTARTS   AGE
pod/frontend-6c99b95f86-lmhmj   1/1     Terminating   0          2m2s
...

I'm happy to take a whack at this myself if you want, just wasn't sure if it might a quick fix for someone more familiar with the code (assuming it's a change worth adding).

/kind feature

@FabianKramm
Copy link
Member

@FabianKramm FabianKramm commented Jun 22, 2020

@ralfthewise thanks for opening this issue! Yes sounds good, I think we can change that, would be great if you could open a PR for this (you can simply change the default ENTRYPOINT and CMD in this file https://github.com/devspace-cloud/devspace/blob/master/cmd/dev.go#L648).

@ralfthewise
Copy link
Author

@ralfthewise ralfthewise commented Jun 22, 2020

Sounds good, will do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.