Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
badges earned

Your Points Tracker
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Does kubectl port forwarding work from within a bitbucket pipeline? Edited


I'm using `kubectl` to set up and install/deploy kubernetes deployments from within Bitbucket Pipelines.


For integration testing, I'm trying to use port-forwarding to send traffic from the bitbucket pipeline to my cluster.


This process works fine for me locally with the same environment variables.

However, I get timeouts after my port-forward step.


Screen Shot 2019-12-17 at 10.41.00 am.png

Screen Shot 2019-12-17 at 10.41.08 am.png

The picture shows me *attempting* to use a `curl` as part of my debugging to actually try out the connection, but it's just timing out. If this works, then I'd go back to just running my original integration tests.



1. has anybody successfully done this? port-forward from within a bitbucket pipeline step to a kube cluster to do stuff?

2. are there any security things on bitbucket (firewalls? closed ports? permissions? something? - not a security person) that may be preventing this from working?



1 answer

Brain eventually caught up.  
if all the pipelines are being run within a docker container - probably - that is being run in a secure mode - probably - stuff running inside won’t have access to exiting the container via random ports.  

which basically means that what I’ve been going to do isn’t possible.  

time to go look for another solution.  

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket

New improvements to user management in Bitbucket Cloud 👥

Hey Community! We’re willing to wager that quite a few of you not only use Bitbucket, but administer it too. Our team is excited to share that we’ll be releasing improvements throughout this month of...

291 views 2 10
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you