Skip to main content

Command Palette

Search for a command to run...

Create dynamic S3 bucket using Azure Pipeline in AWS

Published
1 min read
## Step-1: Download AWS CLI plugin from Marketplace in Azure DevOps Portal
```

```

## Step-2: In AWS Portal, Create either a role or Secret key
```

```

## Step-3: Use the following yml file and apply it to azure pipeline
```
trigger:
- none

pool:
  vmImage: ubuntu-latest

parameters:
  - name: S3BucketName
    displayName: Display name of the S3 bucket you want to create
    type: string
    default: ''

steps:
- task: AWSCLI@1
  displayName: 'Create S3 bucket'
  inputs:
    awsCredentials: 'aws_azure_devops'
    regionName: 'us-east-1'
    awsCommand: 's3api'
    awsSubCommand: 'create-bucket'
    awsArguments: '--bucket ${{ parameters.S3BucketName }} --region us-east-1'
```