Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
youyo committed Nov 9, 2019
1 parent 1bc6a4c commit 5676d1a
Showing 1 changed file with 12 additions and 20 deletions.
32 changes: 12 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ AWS assume role credential wrapper.

awscredswrap uses temporary credentials for the specified iam role to set a shell environment variable or execute a command.

# Use as CLI
## Use as CLI

## Install
### Install

- Brew

Expand All @@ -21,7 +21,7 @@ $ brew install youyo/tap/awscredswrap

Other platforms are download from [github release page](https://github.com/youyo/awscredswrap/releases).

## Usage
### Usage

```bash
$ awscredswrap --help
Expand All @@ -39,13 +39,13 @@ Flags:
--version version for awscredswrap
```

### As command wrapper
#### As command wrapper

```console
$ awscredswrap --role-arn arn:aws:iam::00000000:role/foo -- some_command [arg1 arg2...]
```

### As env exporter
#### As env exporter

When awscredswrap is executed with no arguments, awscredswrap outputs shell script to export AWS credentials environment variables.

Expand All @@ -65,31 +65,23 @@ $ eval $(awscredswrap --role-arn arn:aws:iam::00000000:role/foo)

Temporary credentials has expiration time (about 1 hour).

# Use as GitHub Actions
## Use as GitHub Actions

## Inputs
### Inputs

### `role_arn`
- `role_arn` **Required** The arn of the role to assume.
- `role_session_name` An identifier for the assumed role session. (default awscredswrap@GitHubActions)
- `duration_seconds` The duration, in seconds, of the role session. (default 3600)

**Required** The arn of the role to assume.

### `role_session_name`

An identifier for the assumed role session. (default awscredswrap@GitHubActions)

### `duration_seconds`

The duration, in seconds, of the role session. (default 3600)

## ENV
### ENV

- `AWS_ACCESS_KEY_ID` **Required**
- `AWS_SECRET_ACCESS_KEY` **Required**
- `AWS_DEFAULT_REGION` **Required**

Recommended to get `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` from secrets.

## Example usage
### Example usage

```yaml
on: [push]
Expand Down

0 comments on commit 5676d1a

Please sign in to comment.