AWS CLI¶
Perform the following steps to set up AWS CLI:
- On the Privacera Portal, click Launch Pad from the left menu.
- In the AWS Services section, click AWS CLI to open the AWS CLI dialog.
- Under Configure Script in the AWS CLI dialog, click Download Script to save the script to your local machine.
- Alternatively, you can use
wget
to pull this script to your execution platform, as shown below. Substitute your installation's Privacera Platform host domain name or IPv4 address for<PRIVACERA_PORTAL_HOST>
. - Copy the downloaded script to your home directory.
- Set this file to be executable:
Bash
All the commands should be run with a space between the dot (.) and the script name (~/privacera_aws.sh)
- Under the AWS Cli Generate Token section, generate a platform token.
- Under Generate the Configuration Token, select Never Expire to generate a token that does not expire. Click Generate.
- Run the following command:
Bash - Enter Privacera Access Token and Privacera Secret Token displayed on the portal under the Generate Token section.
- To run AWS CLI command with profile configuration, you need to set up the profile. This can be done by running the following command, replacing <profile-name> with the desired profile name:
Bash - To run any AWS CLI command with endpoint configuration, you need to enable endpoint configuration. This can be done by running the below command
Bash - Under the Check Status section, run the below command to check all the configuration and dependencies status.
Bash - Run your aws commands
Bash - If you get SSL validation failed error then try below commands
- On the Privacera Portal, click Launch Pad -> Setup AWS CLI from the left menu.
- Under Configure Script in AWS CLI, click Download Token to save the token to the
.privacera
folder in your home directory, (e.g.,$HOME/.privacera/privacera_token
). - Click Download Script to save the script to your home directory, (e.g.,
$HOME/privacera_aws.sh
). Make this file executable by running:Bash - To run any AWS CLI command with profile configuration, you need to set up the profile. This can be done by running the following command. Replace with the profile name you want to use for the CLI, such as
default
.Bash - Under the Check Status section, run the below command to check the status of all configurations and dependencies:
Bash - To disable Privacera CLI, run the below command:
Bash - Once you have configured the AWS CLI, you can run the following command to list S3 buckets:
Bash