Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Bitbucket cloud repo automatically push codes into our local private windows machine when commit.

Edited

We have repo in bitbucket cloud. whenever commit happens we need automatically push codes into our file location. we have multiple local windows machine. i tried the FTP method and SSH both need public IP but we need each server to get a public IP thats a long process. is there any method to create a pipeline to automatically push codes into local private windows machine. previosly i tried this code

script:
- pipe: atlassian/ftp-deploy:0.3.7
variables:
USER: $FTP_USERNAME
PASSWORD: $FTP_PASSWORD
SERVER: 172.27.140.71
REMOTE_PATH: /tmp/my-remote-directory
LOCAL_PATH: /,
EXTRA_ARGS: "--exclude=filename_to_exclude.txt --exclude=folder_to_exclude/"

its not woeking so i tried openSSH method

image: node:14

pipelines:
default:
- step:
name: Deploy to Windows Server
script:
- apt-get update && apt-get install -y openssh-client
- ssh -T $USERNAME@$HOST
cd C:\databottest
git clone git@bitbucket.org:<redacted>/<redacted>.git .
git checkout master
git pull origin master

this is also not working i added known host and open 22 port also, please suggest me best way to communicate cloud to local network.

1 answer

0 votes
Patrik S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Feb 07, 2023

Hello @Naveenkumar M ,

Thank you for reaching out to Atlassian Community!

When executing your pipeline using Atlassian infrastructure (cloud runners), your builds will run in a cloud environment and to access external resources, such as your windows servers, these servers will need to have a public IP address so they are reachable from the internet.

In order to access servers in your local network you have the option to use self-hosted runners, so the build will run in your own infrastructure and have access to the servers within your local network.

Another option would be to implement a script/job in each of the servers that keep pulling (git pull) the repository from bitbucket every X minutes, so you would get the latest update from the repo every time the job runs.

Hope that helps to address your questions! 

Thank you, @Naveenkumar M 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events