Skip to content

Instantly share code, notes, and snippets.

@omar-yassin
Created April 30, 2015 14:11
Show Gist options
  • Save omar-yassin/f25b5a17f0f7084eecfd to your computer and use it in GitHub Desktop.
Save omar-yassin/f25b5a17f0f7084eecfd to your computer and use it in GitHub Desktop.
AWS EC2 Powershell Cheatlist
$EC2_launch_time = Get-Date (Get-EC2Instance -Instance $instanceId | % { $_.RunningInstance } | Select-Object -expand LaunchTime) -format "M/d/yyyy hh:mm:ss tt"
$Windows_bootTime = Get-Date (Get-CimInstance -ClassName win32_operatingsystem | select -expand lastbootuptime).tostring().trim() -format "M/d/yyyy hh:mm:ss tt"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment