Working With AWS Cloud Services Flashcards

Understand how to access and manage AWS services

1
Q

Different ways to manage AWS resources

A

AWS management console (Web application)

AWS command line interface (CLI )

AWS Software Development Kit (SDK)

AWS Tools for powershell

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Installing AWS CLI in windows/MAC/Linux

A

Windows OS have 32 bit/ 64 bit installer.

For MAC/Linux OS, you need to have pip and python available and then run the below command.

“pip install aws cli”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Upgrading AWS CLI

A

“pip install –upgrade awscli” is the command required to upgrade AWS CLI on a linux or MAC OS running machines.

For windows, download the latest installer and install the latest version.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

$ aws configure

A

New configuration can be created using the ‘aws configure’ command.

$ aws configure

This will ask us to set “AWS Access Key ID” and “Default region name”.

By default both values are set to ‘None’

There are two keys created for your IAM user by IAM service initially during configuration.

1) Access key
2) Secret Key

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

AWS profiles

A

Profiles are used to define access previleges for different environments (like stage,dev and prod).

$aws configure –profile

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Location of AWS credentials and configuration

A

AWS credentials are stored in “credentials” file located in “.aws” subdirectory under home directory of the user. Configuration is stored in “config” file in “.aws” subdirectory.

Location in linux

Path for Credentials: ~/.aws/credentials
Path for Configuration: ~/.aws/config

Location in windows

Path for Credentials: %UserProfile%.aws/credentials
Path for Configuration: %UserProfile%.aws/config

CLI will check this file for credentials everytime.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Environment Variables

A

AWS CLI can also be configured with the help of Environment Variables.

Environment Variables can be set using following command in linux/mac.

“export environment_variable = option” to set the new variable.

Some of the environment Variables are

AWS_DEFAULT_PROFILE
AWS_DEFAULT_REGION
AWS_CONFIG_FILE

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

work with aws services in CLI

A

To work with aws services in CLI, we have to use the following command.

aws service parameter1 … parameter2…parameterN

For example: Command “aws ec2 describe-instances”, will return a list of EC2 instances, along with their properties running in your configured region.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Output types in CLI

A

We can configure “default output type” of CLI in aws config file.

You can represent the data retrieved using AWS CLI in three output formats.

1) JSON,
2) Text
3) Table

JSON is the default format.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Boto and its installation

A

AWS SDK for python is also know as “Boto”.

It is available as open source project.

Given that Boto is SDK for python, it requires python to be installed prior to its own installation.

Another prerequisite is “pip”, a python tool for installing packages.

Boto can be installed using pip command.

“pip install boto3” (current version of boto SDK is 3)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Features of Boto

A

Boto contains high level and low level APIs

Low level APIs (client API) are mapped to AWS cloud specific service APIs.

High level APIs (Resource API) are mapped to AWS cloud services, but a way (object oriented) it calls is different from Low level APIs.

Waiter: waiter allows structure that allows for code to wait for changes to occur in the cloud.

Multithreading is possible in boto.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How to use Boto in python code.

A

You can start using by importing Boto SDK.

Command to import:

“Import boto3”

Number 3 points to boto version.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly