Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $ENV:Path = $ENV:Path+";C:\Program Files (x86)\Putty"
- $UNIX_USERNAME = Read-Host "Enter Username"
- $UNIX_PASSWORD = Read-Host "Enter Unix Password" -AsSecureString
- $CONTROLLER_PASSWORD = Read-Host "Enter Controller Password" -AsSecureString
- Function IP-Ping {
- Param ([Parameter(Mandatory=$true)][string]$hostname)
- cmd /c start ping $hostname -t
- }
- Set-Alias sa Set-Alias
- sa p IP-Ping
- Function Reg-Login{
- Param ([Parameter(Mandatory=$true)][string]$store,[Parameter(Mandatory=$true)][string]$reg)
- $hostname= -join ("s0",$store,"reg",$reg)
- putty_6_3.exe -ssh $hostname -l $UNIX_USERNAME -pw ( [System.Runtime.InteropServices.Marshal]::PtrToStringAuto([System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($UNIX_PASSWORD)) )
- }
- Function Reg-Ping{
- Param ([Parameter(Mandatory=$true)][string]$store,[Parameter(Mandatory=$true)][string]$reg)
- $hostname= -join ("s0",$store,"reg",$reg)
- p $hostname
- }
- Function EuISS-Login{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"isp1")
- putty_6_3.exe -ssh $hostname -l root -pw 1ss2010! -P 2222
- }
- Function Ctr-Login{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"ctr1")
- putty_6_3.exe -ssh $hostname -l $UNIX_USERNAME -pw ( [System.Runtime.InteropServices.Marshal]::PtrToStringAuto([System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($CONTROLLER_PASSWORD)) ) -P 2222
- }
- Function Ctr-Ping{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"ctr1")
- p $hostname
- }
- Function ISS-Login{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"isp1")
- putty_6_3.exe -ssh $hostname -l $UNIX_USERNAME -pw ( [System.Runtime.InteropServices.Marshal]::PtrToStringAuto([System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($UNIX_PASSWORD)) )
- }
- Function ISS-Ping{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"isp1")
- p $hostname
- }
- Function ISS-Drac{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $url= -join("s0",$store,"isp1-drac/")
- Start-Process chrome $url
- }
- Function Sw-Login{
- Param ([Parameter(Mandatory=$true)][string]$store,[Parameter(Mandatory=$true)][string]$sw)
- $hostname= -join ("s0",$store,"sw0",$sw)
- putty_6_3.exe -ssh $hostname -l $UNIX_USERNAME
- }
- Function Rtr-Ping{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"rtr1")
- p $hostname
- }
- Function Rtr-Login{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"rtr1")
- putty_6_3.exe -ssh $hostname -l $UNIX_USERNAME
- }
- Function Clk-Login{
- Param ([Parameter(Mandatory=$true)][string]$store)
- $hostname= -join ("s0",$store,"clk1")
- putty_6_3.exe -ssh $hostname -l $UNIX_USERNAME -pw ( [System.Runtime.InteropServices.Marshal]::PtrToStringAuto([System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($UNIX_PASSWORD)) )
- }
- Function iPod-Search{
- Param ([Parameter(Mandatory=$true)][string]$sn)
- $url= -join("https://gapstorescn.awmdm.com/AirWatch/#/AirWatch/Device/List/Search?searchText=",$sn)
- Start-Process chrome $url
- }
- Function IntForce-Close{
- Start-Process chrome http://sslbox.gap.com:8080/job/intl-register-force-close/build?delay=0sec
- }
- Function AP-Ping{
- Param ([Parameter(Mandatory=$true)][string]$store,[Parameter(Mandatory=$true)][string]$ap)
- $hostname= -join ("s0",$store,"ap0",$ap)
- p $hostname
- }
- sa cl Ctr-Login
- sa cop Ctr-Ping
- sa ip ISS-Ping
- sa id ISS-Drac
- sa il ISS-Login
- sa is iPod-Search
- sa rtp Rtr-Ping
- sa rep Reg-Ping
- sa rl Reg-Login
- sa rtl Rtr-Login
- sa ap AP-Ping
Add Comment
Please, Sign In to add comment