Skip to content

Commit b78f0ca

Browse files
committed
got first initial run working
we now setup both ~/.aws/credentials and ~/.aws/config for you
1 parent 897ea53 commit b78f0ca

File tree

6 files changed

+216
-152
lines changed

6 files changed

+216
-152
lines changed

README.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ Usage
144144
-----
145145

146146
```
147-
--device arn:aws:iam::123456788990:mfa/dudeman
147+
--device arn:aws:iam::123456788990:mfa/mirandel-smith
148148
The MFA Device ARN. This value can also be provided
149149
via the environment variable 'MFA_DEVICE' or the
150150
~/.aws/credentials variable 'aws_mfa_device'.
@@ -192,31 +192,31 @@ Run **aws-mfa** *before* running any of your scripts that use any AWS SDK.
192192
Using command line arguments:
193193

194194
```sh
195-
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/dudeman
195+
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/mirandel-smith
196196
INFO - Using profile: default
197197
INFO - Your credentials have expired, renewing.
198-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):123456
198+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):123456
199199
INFO - Success! Your credentials will expire in 1800 seconds at: 2015-12-21 23:07:09+00:00
200200
```
201201

202202
Using environment variables:
203203

204204
```sh
205-
export MFA_DEVICE=arn:aws:iam::123456788990:mfa/dudeman
205+
export MFA_DEVICE=arn:aws:iam::123456788990:mfa/mirandel-smith
206206
$> aws-mfa --duration 1800
207207
INFO - Using profile: default
208208
INFO - Your credentials have expired, renewing.
209-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):123456
209+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):123456
210210
INFO - Success! Your credentials will expire in 1800 seconds at: 2015-12-21 23:07:09+00:00
211211
```
212212

213213
```sh
214-
export MFA_DEVICE=arn:aws:iam::123456788990:mfa/dudeman
214+
export MFA_DEVICE=arn:aws:iam::123456788990:mfa/mirandel-smith
215215
export MFA_STS_DURATION=1800
216216
$> aws-mfa
217217
INFO - Using profile: default
218218
INFO - Your credentials have expired, renewing.
219-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):123456
219+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):123456
220220
INFO - Success! Your credentials will expire in 1800 seconds at: 2015-12-21 23:07:09+00:00
221221
```
222222

@@ -231,29 +231,29 @@ INFO - Your credentials are still valid for 1541.791134 seconds they will expire
231231
Using a profile: (profiles allow you to reference different sets of credentials, perhaps for different users or different regions)
232232

233233
```sh
234-
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/dudeman --profile development
234+
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/mirandel-smith --profile development
235235
INFO - Using profile: development
236-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):666666
236+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):666666
237237
INFO - Success! Your credentials will expire in 1800 seconds at: 2015-12-21 23:09:04+00:00
238238
```
239239

240240
Using a profile that is set via the environment variable `AWS_PROFILE`:
241241

242242
```sh
243243
$> export AWS_PROFILE=development
244-
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/dudeman
244+
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/mirandel-smith
245245
INFO - Using profile: development
246-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):666666
246+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):666666
247247
INFO - Success! Your credentials will expire in 1800 seconds at: 2015-12-21 23:09:04+00:00
248248
```
249249

250250
Assuming a role:
251251

252252
```sh
253-
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/dudeman --assume-role arn:aws:iam::123456788990:role/some-role --role-session-name some-role-session
253+
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/mirandel-smith --assume-role arn:aws:iam::123456788990:role/some-role --role-session-name some-role-session
254254
INFO - Validating credentials for profile: default with assumed role arn:aws:iam::123456788990:role/some-role
255255
INFO - Obtaining credentials for a new role or profile.
256-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):123456
256+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):123456
257257
INFO - Success! Your credentials will expire in 1800 seconds at: 2016-10-24 18:58:17+00:00
258258
```
259259

@@ -267,16 +267,16 @@ assume_role = arn:aws:iam::123456788990:role/some-role
267267
```
268268

269269
```sh
270-
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/dudeman --role-session-name some-role-session
270+
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/mirandel-smith --role-session-name some-role-session
271271
```
272272

273273
Assuming a role using a profile:
274274

275275
```sh
276-
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/dudeman --profile development --assume-role arn:aws:iam::123456788990:role/some-role --role-session-name some-role-session
276+
$> aws-mfa --duration 1800 --device arn:aws:iam::123456788990:mfa/mirandel-smith --profile development --assume-role arn:aws:iam::123456788990:role/some-role --role-session-name some-role-session
277277
INFO - Validating credentials for profile: development with assumed role arn:aws:iam::123456788990:role/some-role
278278
INFO - Obtaining credentials for a new role or profile.
279-
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/dudeman] (renewing for 1800 seconds):123456
279+
Enter AWS MFA code for device [arn:aws:iam::123456788990:mfa/mirandel-smith] (renewing for 1800 seconds):123456
280280
INFO - Success! Your credentials will expire in 1800 seconds at: 2016-10-24 18:58:17+00:00
281281
```
282282

0 commit comments

Comments
 (0)