Objective: Set up AWS Buckets for our application!
At this stage of our insurance application, we are now going to be working with S3. We want to use Amazon’s web Services to upload our data files.
If you have been following along than you will have an AWS folder in the project view. Inside that folder is an example folder, and inside that example folder is a S3Example scene. Load the scene and let’s see what we can do.
If you select the S3 game object in the Hierarchy, you will see it has an Identity Pool ID.
We need to go back to our AWS account.
Log in. We need to get out Identity Pool. Go to Cognito under the recently visited services.
From here select “Manage Identity Pools.”
Select your app.
This brings you to a dashboard that shows the apps analytics. Under “Dashboard” on the left is ‘Sample Code’ that contains our AWS credentials. In Dashboard, select “Edit Identity Pool” in the upper right-hand corner.
This will give us our Identity Pool ID. Copy it, and head back into Unity. Paste the Identity Pool into the S3Example object.
We now want to go through the S3Example script and see how it’s pulling that data/ what it is doing with our Identity Pool.
We can see it has a string for Identity Pool we just assigned, as well as a S3BucketName. We may need to update that information. Let’s head back to our AWS account.
Type “S3” and select “Scalable Storage in the Cloud”
From here we are going to create a bucket. Buckets are globally unique containers for everything you store on Amazon S3. After you create a bucket, you can upload your objects i.e. (Photos/ Videos/ Data Files) Click Create Bucket.
Create something clever for your bucket name.
Select the AWS region that is best for you. For now, you can leave all the public access blocked. You can come in later and adjust the access at a later date if you need. Click Create Bucket and now you have a bucket.
With our bucket created and ready we can once again head back to Unity and update the Bucket Name in the S3Example object.
Now the bucket and the Identity Pool is attached and ready for use. In the next tutorial we are going to start AWS S3 services. I’ll see you in the next tutorial!