Skip to content

Defers run in cmd/envbuilder won't execute because Run performs execve(2) #364

@mafredri

Description

@mafredri
Member
          Review: Even though we've fixed defers here, there's still `cmd/envbuilder` where e.g. `closeLogs` won't fire since we execve(2) after this.

Originally posted by @mafredri in #359 (comment)

Activity

johnstcn

johnstcn commented on Sep 27, 2024

@johnstcn
Member

We could maybe add a PreExec []func() field to envbuilder.Options that will get called right before we Exec?

Edit: it's simpler to just pass them into Run() / RunCacheProbe.

self-assigned this
on Sep 27, 2024
added a commit that references this issue on Sep 27, 2024
9ee20e7
johnstcn

johnstcn commented on Sep 27, 2024

@johnstcn
Member

Need to be careful about LogSenderV2 (see #371); will fix this later.

added a commit that references this issue on Sep 30, 2024
481e3a9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Participants

    @mafredri@johnstcn

    Issue actions

      Defers run in `cmd/envbuilder` won't execute because Run performs `execve(2)` · Issue #364 · coder/envbuilder