---
title: AWS S3
---
## You can create an AWS S3 bucket to store your uploaded documents using OpenSign™

### AWS S3 -
- **Step 1 : Create a S3 bucket**
  - Login to [AWS console](https://aws.amazon.com/console/)
  - Navigate to S3 under services.
    ![Screenshot 2024-09-30 203247](https://github.com/user-attachments/assets/1a734349-1c1a-4f53-8582-7318c22911f5)
  - Hit "Create Bucket" button on upper right corner.
    ![Screenshot 2024-09-30 195246](https://github.com/user-attachments/assets/b036fa3b-20c4-4348-8697-68bcf2fd9de3)
  - Now provide bucket name and don't change any other options scroll down and click on "Create Bucket" button.
    ![Screenshot 2024-09-30 195603](https://github.com/user-attachments/assets/3fb1a591-fffd-4703-9b1f-9cb1edbdf7fe)
    ![Screenshot 2024-09-30 195835](https://github.com/user-attachments/assets/a0b2be8a-a273-474d-88d5-614cb42de8dd)
  - Click on name of bucket from list which we have just created.
  - Now go to permission Tab and scroll down to bottom.
    ![Screenshot 2024-09-30 202035](https://github.com/user-attachments/assets/dbf44b05-370b-40f8-bfc1-fd2f8441da46)
  - At the bottom you will see cross-origin resource sharign (cors) section click on "Edit" button.
    ![Screenshot 2024-09-30 202057](https://github.com/user-attachments/assets/a9fb13b3-7a30-4c49-b3ea-6a30a2b7c357)
  - Now paste below line of code and add origin url in AllowedOrigins array and click on "Save changes".
    ```   
    [
        {
            "AllowedHeaders": [
                "*"
            ],
            "AllowedMethods": [
                "GET",
                "PUT",
                "POST"
            ],
            "AllowedOrigins": [
                "https://localhost:3001",
                "https://app.opensignlabs.com",
    "https://eu-app.opensignlabs.com"
            ],
            "ExposeHeaders": [
                "x-amz-server-side-encryption",
                "x-amz-request-id",
                "x-amz-id-2"
            ],
            "MaxAgeSeconds": 3000
        }
    ]
    ```
  - Once completed, navigate to "Properties," where you'll find the bucket region (e.g., us-east-1).
  - Set the bucket name you created in step 1 as the value for "DO_SPACE" in the ENV file.
  - Assign the region value to the "DO_REGION" variable in the ENV file.
  - Replace the region in the URL s3.region.amazonaws.com and set it as "DO_ENDPOINT" in the ENV file.
  - Replace both the bucket name and region in the URL https://bucketName.s3.region.amazonaws.com and set it as "DO_BASEURL" in the ENV file.
    
- **Step 2 : Create a aws policy**
  - Navigate to IAM under services
    ![Screenshot 2024-09-30 200247](https://github.com/user-attachments/assets/8109d2bb-1afb-4407-b5cd-4886a070d5cc)
  - Now click on "Polices" from left side "access management" menu.
  - Hit "Create Policy" button on upper right corner.
    ![Screenshot 2024-09-30 200939](https://github.com/user-attachments/assets/1b3b5608-9a84-477d-b46e-aaf884a73343)
  - Search for S3 and Tick "PutObject" and "GetObject" from "Specify permissions" screen.
    ![Screenshot 2024-09-30 200537](https://github.com/user-attachments/assets/7168d261-abc4-4789-8e64-628c81c79e24)
    ![Screenshot 2024-09-30 200607](https://github.com/user-attachments/assets/863f8e7c-74eb-4f1b-9ea5-41524ba249ca)
  - Select "All" under Resources
![Screenshot 2024-09-30 200929](https://github.com/user-attachments/assets/c4b26336-aab0-49c3-a817-d2a71d603091)
  - provide policy name and hit on 'Create Policy".
    ![Screenshot 2024-09-30 200808](https://github.com/user-attachments/assets/4db2ab95-14bb-4ea1-a9a3-821e20e70038)  
- Step 3 : Create IAM user.
  - Now click on "Users" from left side "access management" menu and then click on "Create User" button.
    ![Screenshot 2024-09-30 201026](https://github.com/user-attachments/assets/1aa1f071-6291-457f-a514-970f511866cb)
  - Provide username and click on Next button.
  - Now select "Attach policies directly" from Permissions options.
    ![Screenshot 2024-09-30 201731](https://github.com/user-attachments/assets/13c6d571-d3da-4259-8f04-8ec130d9091a)
  - Now, search for the policy we created in the previous step within the "Permissions Policies" section.
    ![Screenshot 2024-09-30 201742](https://github.com/user-attachments/assets/c2b1643d-e3e3-49ee-920b-641e7ff819f5)
  - Now scroll down and  Click on "Create User" Button.
- Step 4 : Generate Credentials
  - Now Click on username form list which we have created in previous step.
  - Navigate to "Security credentials".
  - Click on "Create Access Key" from right corner.
    ![Screenshot 2024-09-30 201850](https://github.com/user-attachments/assets/d25abe2f-0cfc-4cc0-a02c-6b9fc6559dd2)
  - In the next step select "Application running outside AWS".
    ![Screenshot 2024-09-30 201917](https://github.com/user-attachments/assets/f9b0cdb2-3718-4ae6-a4ba-68e144d1f4a1)
  - In the next step, you will see the "Access key" and "Secret Access key." Copy both values.
  - Assign the "Access key" value to the "DO_ACCESS_KEY_ID" environment variable.
  - Assign the "Secret Access key" value to the "DO_SECRET_ACCESS_KEY" environment variable.

If you encounter any issues while following these instructions, refer to the link below:  - https://repost.aws/knowledge-center/create-access-key
