Closed danielpapst closed 8 years ago
Thanks for reporting these issues when using our examples with PowerShell. Will add this to our errata.
Had a deeper look. As stated in the introduction we are only covering the AWS CLI via Shell/Bash in our book. Might be an option to add an appendix for PowerShell with the next revision. Depending on demand. Easiest way to follow our examples might be to launch an EC2 instance (Amazon Linux) and execute the command there.
You indicate that you're using the command line by prepending "$ " to the commands.
For instance: $ aws cloudformation describe-stacks --stack-name vpn --query Stacks[0].Outputs --output text
For the initialization of variables you need to prepend a $ to the variable identifier.
Won't work: $ VpcId=$(aws ec2 describe-vpcs --query Vpcs[0].VpcId --output text)
Will work: $ $VpcId=$(aws ec2 describe-vpcs --query Vpcs[0].VpcId --output text)