1. When creating vpc in cli, the jq command was used and the vpcid output was successful.
2. There was a problem enabling the DNS hostname
3. The echo$vpcid should print the defined vpcid, but nothing
1. When creating vpc in cli, the jq command was used and the vpcid output was successful.
This is not a value setting for the variable vpcid
, but simply the string vpcid=
followed by the command execution results below awsec2.
Use the jq command to create the vpc in 1.cli, and immediately after the vpcid output without any problems
echo$vpcid
3.echo$vpcid should print the defined vpcid, but it should be the same as the empty
.
If you divide the substitution into variables and echo as follows, you will get the desired result.
vpcid=$(awsec2 and below...)
echo$vpcid
© 2024 OneMinuteCode. All rights reserved.