Skip to content

Commit ddde140

Browse files
committed
AWS S3 documentation major update
1 parent 02383a9 commit ddde140

File tree

2 files changed

+54
-11
lines changed

2 files changed

+54
-11
lines changed

content/arduino-cloud/09.business/02.aws-s3-exporter/content.md

Lines changed: 54 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ The data extraction is managed by a scheduled AWS Lambda function that operates
2222

2323
## Goals
2424

25+
* Learn to create S3 Bucket and CloudFormation Stack
2526
* Understand the functionality of the Arduino AWS S3 CSV Exporter
2627
* Learn how to configure and deploy the Lambda function for data extraction
2728
* Set up filtering and resolution options for optimized data aggregation
@@ -53,7 +54,7 @@ If you do not have an existing AWS account and user, refer to the [online AWS do
5354
- [Sign up for an AWS account](https://docs.aws.amazon.com/iot/latest/developerguide/setting-up.html#aws-registration)
5455
- [Create an administrative user](https://docs.aws.amazon.com/iot/latest/developerguide/setting-up.html#create-an-admin)
5556

56-
The exporter setup involves deploying resources using a [**CloudFormation template**](https://github.com/arduino/aws-s3-integration/blob/0.3.0/deployment/cloud-formation-template/deployment.yaml). Ensure your AWS account has permissions for:
57+
The exporter setup involves deploying resources using a [**CloudFormation template**](https://github.com/arduino/aws-s3-integration/blob/0.3.0/deployment/cloud-formation-template/deployment.yaml). The AWS account will be set to have permission for:
5758

5859
* CloudFormation stack creation (policy: `AWSCloudFormationFullAccess`)
5960
* S3 bucket management (policy: `AmazonS3FullAccess`)
@@ -128,62 +129,104 @@ Once every file is uploaded, the binaries and CFT file will be listed within the
128129

129130
#### CSV Destination Bucket
130131

131-
Another bucket needs to be created following a similar process used to create [Temporary bucket](#temporary-bucket). This bucket will be the **CSV destination bucket**, where all generated CSV files will be uploaded. Make sure this bucket is in the same AWS region where the stack will be created.
132+
A second bucket needs to be created following the same process as the [Temporary bucket](#temporary-bucket). This bucket will be the **CSV destination bucket**, where all generated CSV files will be stored. It is important to make sure this bucket is created in the same AWS region where the CloudFormation stack will be deployed.
133+
134+
Navigate to the Amazon S3 service and select Create bucket. In the bucket creation interface, specify the bucket name and confirm that the correct AWS region is selected.
135+
136+
Keep the recommended default settings for Object Ownership and Public Access to maintain security compliance. Once all settings are verified, proceed with the bucket creation.
132137

133138
![lambdas3binaries Bucket Setup (1)](assets/s3_bucket_csvdests3int_1.png)
134139

140+
After the bucket has been successfully created, it will be listed among other existing buckets. Select the newly created CSV destination bucket to continue with additional configurations if necessary.
141+
135142
![lambdas3binaries Bucket Setup (2)](assets/s3_bucket_csvdests3int_2.png)
136143

144+
Inside the CSV destination bucket, navigate to the **Objects** tab. Here, you can organize files by creating folders if needed.
145+
146+
Click on the **Create folder** button and specify a name for the directory that will store the exported CSV files.
147+
137148
![lambdas3binaries Bucket Setup (3)](assets/s3_bucket_csvdests3int_3.png)
138149

150+
When creating a folder, you will see options for server-side encryption to protect data at rest. By default, encryption settings are inherited from the bucket's global configuration.
151+
152+
If needed, specify a custom encryption key before creating the folder.
153+
139154
![lambdas3binaries Bucket Setup (4)](assets/s3_bucket_csvdests3int_4.png)
140155

156+
Once the folder is created, it will be displayed under the Objects tab of the CSV destination bucket. This ensures that all exported CSV files will be stored well-organized within the dedicated bucket.
157+
141158
![S3 Buckets](assets/s3_bucket_complete.png)
142159

143160
## Creating CloudFormation Stack
144161

162+
To create the CloudFormation stack, navigate to the AWS CloudFormation service and select Create stack. This process involves specifying a template source.
163+
145164
![Stack Creation (1)](assets/cloud_stack_create_1.png)
146165

166+
Choose the option to use an existing template and enter the Amazon S3 URL for the CloudFormation template.
167+
147168
![Stack Creation (2)](assets/cloud_stack_create_2.png)
148169

149-
Note the following object URL for use in the stack creation process:
170+
The following **Object URL** is an example of how it looks for use in the stack creation process:
150171

151172
```bash
152173
https://arduino-s3-data-exporter-deployment.s3.amazonaws.com/deployment.yaml
153174
```
154175

155176
The **Object URL** is required for the **Amazon S3 URL** field within the stack creation.
156177

178+
Proceed with the stack creation by following the steps. The configuration requires specifying parameters, including the Arduino API key and secret, the S3 bucket for code storage and the CSV destination bucket.
179+
180+
Optional parameters such as tag filters, organization ID and data resolution settings can also be configured.
181+
157182
![Stack Creation (3)](assets/cloud_stack_create_3.png)
158183

159-
Use the CloudFormation console to create a new stack.
184+
Once all parameters are set, review the configuration to ensure all details are correct before proceeding to create a new stack.
160185

161186
![Stack Creation (4)](assets/cloud_stack_create_4.png)
162187

163188
### Stack Parameters
164189

165-
![Stack Creation - Paramters (5)](assets/cloud_stack_create_5.png)
190+
In the **Specify stack details** step, provide a stack name and enter the necessary parameters.
166191

167-
Enter the following parameters required for creating the stack:
168-
192+
The **`DestinationS3Bucket`** is the location where the CSV files will be stored.
193+
194+
The **`LambdaCodeS3Bucket`** refers to the bucket containing the Lambda function ZIP file.
195+
196+
Specify the corresponding API key and secret in the `IotApiKey` and `IotApiSecret` fields.
197+
198+
![Stack Creation - Parameters (5)](assets/cloud_stack_create_5.png)
199+
200+
The parameters required for creating the stack are categorized as follows:
201+
 
169202
- **Mandatory:** Arduino API key and secret, the S3 bucket for code, and the destination S3 bucket.
170203
- **Optional:** Tag filter, organization ID, and data resolution settings.
171204

172-
![Stack Creation - Paramters (6)](assets/cloud_stack_create_6.png)
205+
![Stack Creation - Parameters (6)](assets/cloud_stack_create_6.png)
173206

174-
![Stack Creation - Review (7)](assets/cloud_stack_create_7.png)
207+
Additional parameters include scheduling execution frequency, resolution settings and optional filters. These settings define how often data is exported and the aggregation method applied to collected data.
175208

176-
![Stack Creation - Review (8)](assets/cloud_stack_create_8.png)
209+
Once all parameters are filled in, proceed to the review stage. This allows you to verify the stack configuration before finalizing the deployment.
210+
211+
![Stack Creation - Review (7)](assets/cloud_stack_create_7.png)
177212

178213
![Stack Creation - Complete Review](assets/cloudformation_stack_step4.gif)
179214

180215
### Stack Build
181216

217+
After confirming the stack creation, AWS CloudFormation will begin deploying the required resources.
218+
219+
The stack creation process can be monitored from the AWS CloudFormation Stacks section.
220+
182221
![Stack Build (1)](assets/cloud_stack_creation_1.png)
183222

184223
![Stack Build (2)](assets/cloud_stack_creation_2.png)
185224

186-
![Stack Build Process](assets/cloudformation_stack_creation.png)
225+
The deployment status can be tracked, and once completed, the stack should display the status **`CREATE_COMPLETE`**, indicating that all resources have been successfully deployed.
226+
227+
![Stack Build Process](assets/cloudformation_stack_creation.gif)
228+
229+
This setup ensures that AWS S3 integrates with the Arduino Cloud for automated CSV data export.
187230

188231
![Stack Build Information](assets/cloud_stack_info.png)
189232

0 commit comments

Comments
 (0)