[GH-ISSUE #569] Enhancement: Support publishing ports to host OS #382

Open
opened 2026-03-01 21:42:53 +03:00 by kerem · 3 comments
Owner

Originally created by @bixu on GitHub (Mar 17, 2021).
Original GitHub issue: https://github.com/nektos/act/issues/569

Port publishing similar to Docker's --publish flag

Here's a specific use-case from my org: we run a JUnit test suite in GH Actions, and were trying to debug an issue with suite using Act, but this was difficult because the JVM remote debugger listens on a port inside the Act container and wasn't easily accessible to our dev toolset. If the maintainers would be open to adding port publishing with a flag like --publish (following Docker conventions), we'd might be able to open a PR around this.

CC: @olga-casian

Originally created by @bixu on GitHub (Mar 17, 2021). Original GitHub issue: https://github.com/nektos/act/issues/569 ## Port publishing similar to Docker's `--publish` flag Here's a specific use-case from my org: we run a JUnit test suite in GH Actions, and were trying to debug an issue with suite using Act, but this was difficult because the JVM remote debugger listens on a port inside the Act container and wasn't easily accessible to our dev toolset. If the maintainers would be open to adding port publishing with a flag like `--publish` (following Docker conventions), we'd might be able to open a PR around this. CC: @olga-casian
Author
Owner

@jsoref commented on GitHub (Apr 4, 2021):

The maintainers might be open to this (it doesn't seem terribly unreasonable).

Note that there are ways that should work today:

I haven't tried any of these. I ran across someone offering a tunnel for GHA recently. I'm still trying to get my action to basically work in act, let alone fancy stuff.

Do note that you can run docker exec to connect to the running container, so you could probably bolt something on using some local ncs too.

<!-- gh-comment-id:813018365 --> @jsoref commented on GitHub (Apr 4, 2021): The maintainers might be open to this (it doesn't seem terribly unreasonable). Note that there are ways that _should_ work today: * https://github.com/shaowenchen/debugger-action * https://github.com/csexton/debugger-action * https://github.com/marketplace/actions/debug-via-ssh * https://github.com/marketplace/actions/debugging-with-tmate * https://jacobtomlinson.dev/posts/2021/how-to-interactively-debug-github-actions-with-netcat/ I haven't tried any of these. I ran across someone offering a tunnel for GHA recently. I'm still trying to get my action to basically work in act, let alone fancy stuff. Do note that you can run `docker exec` to connect to the running container, so you could probably bolt something on using some local `nc`s too.
Author
Owner

@bixu commented on GitHub (Apr 9, 2021):

@calleb-sumup

<!-- gh-comment-id:816554767 --> @bixu commented on GitHub (Apr 9, 2021): @calleb-sumup
Author
Owner

@mzagaja commented on GitHub (Mar 31, 2022):

After going through a large debugging adventure with some actions today, adding this feature would be a big win for my developer experience in order to be able to connect a remote debugger to my test suite through TCP.

<!-- gh-comment-id:1084825270 --> @mzagaja commented on GitHub (Mar 31, 2022): After going through a large debugging adventure with some actions today, adding this feature would be a big win for my developer experience in order to be able to connect a remote debugger to my test suite through TCP.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#382
No description provided.