testcontainers-go icon indicating copy to clipboard operation
testcontainers-go copied to clipboard

feat: add reaper for compose

Open oGi4i opened this issue 3 years ago • 3 comments

Closes #372

oGi4i avatar Jun 15 '22 12:06 oGi4i

@mdelapenya Not the most elegant solution, would love to hear your thoughts on this.

oGi4i avatar Jun 15 '22 13:06 oGi4i

Hi @oGi4i, thanks for your first contribution to TC-go.

We are currently reviewing https://github.com/testcontainers/testcontainers-go/pull/463, which could cause this PR to break.

If you agree, I'd like to have your PR after the other one.

mdelapenya avatar Jun 15 '22 16:06 mdelapenya

If you agree, I'd like to have your PR after the other one.

Sure, no problem

oGi4i avatar Jun 15 '22 18:06 oGi4i

Hi @oGi4i we have merged #476, which adds native support for docker compose. Would you mind revisiting this PR and update to that code? I can assist if needed, or we can even ping @baez90 for that.

Thanks in advance

mdelapenya avatar Oct 24 '22 14:10 mdelapenya

@oGi4i I'm closing this issue as stale.

OTOH it would be ideal if the compose APIs allow passing labels to the container CreateOptions (they only provide it for the RunOptions type), which would way simplify this implementation, simplify passing reaper labels as we do in https://github.com/testcontainers/testcontainers-go/blob/main/docker.go#L996-L999

Probably worth it to ping the Docker folks for that support. If they are not responsive, we could try designing this implementation in a similar way that you started here, but adapted to the new code.

In any case, thanks for your time here.

mdelapenya avatar Mar 08 '23 11:03 mdelapenya