This action starts a local or remote port forwarding session for your GitHub workflow and terminates it upon cleanup.
Forked from aws-ssm-port-forwarding-session-action.
See action.yml
Forward instance's i-1234
port 8888
on local port 8888
:
steps:
...
- name: SSM Port Forward
uses: workivate/aws-ssm-port-forwarding-session-action@v1.1.0
with:
target-id: 'i-1234'
portNumber: 8888
localPortNumber: 8888
- name: Curl Test
run: |
curl -v http://127.0.0.1:8888
Use instance i-1234
to forward traffic to database on postgresql-database.cluster-abcd.eu-west-1.rds.amazonaws.com
listening on port 5432
, and bind it to local port 5432
:
steps:
...
- name: SSM Port Forward
uses: workivate/aws-ssm-port-forwarding-session-action@v1.1.0
with:
target-id: 'i-1234'
portNumber: 5432
localPortNumber: 5432
host: postgresql-database.cluster-abcd.eu-west-1.rds.amazonaws.com
- name: PSQL Test
run: |
pg_isready -h 127.0.0.1 -p 5432
At the moment Unix socket port forwarding is not supported.
The scripts and documentation in this project are released under the MIT License