Monday 15 April 2013

ios - Can I ssh to Mac using Windows Command line without using other tool like putty? -



ios - Can I ssh to Mac using Windows Command line without using other tool like putty? -

i have ci scheme on windows build server code.

nowadays, want autobuild ios project daily, can build in mac system.

so write shell script can build ios project on mac, , want remotely execute script windows.

how can write batch file on windows remote access mac , execute script there? can create ci scheme execute batch file everyday automatically.

or... got other improve ways thing?

thanks!

get "plink" putty download page. set command(s) kick off mac shell script in file (e.g. "maccommands.txt") on windows computer. create batch file contains:

plink -l macusername -m maccommands.txt your.mac.ip.address

if don't want prompted password every time, create public-private keypair empty passphrase using puttygen. save private key "pc_rsa.ppk" (or whatever want phone call it). re-create public key out of puttygen window clipboard, , paste in text editor , save (e.g. "pc_rsa_pub.txt").

then transfer file public key on mac, , add together contents end of ~/.ssh/authorized_keys, e.g. cat pc_rsa_pub.txt >> ~/.ssh/authorized_keys add together -i pc_rsa.ppk plink command above utilize private key.

(this has security implications, protect private key file. utilize -pw password has greater security implications password plainly visible within batch file.)

ios windows osx batch-file auto-build

No comments:

Post a Comment