mirror of
https://github.com/OpenSignLabs/OpenSign.git
synced 2026-09-05 01:07:39 +02:00
1 line
9.3 KiB
JavaScript
1 line
9.3 KiB
JavaScript
"use strict";(globalThis.webpackChunkOpenSign_Docs=globalThis.webpackChunkOpenSign_Docs||[]).push([[291],{20833(e,s,t){t.r(s),t.d(s,{assets:()=>r,contentTitle:()=>a,default:()=>d,frontMatter:()=>o,metadata:()=>n,toc:()=>l});const n=JSON.parse('{"id":"self-host/cloud-storage/s3","title":"AWS S3","description":"You can create an AWS S3 bucket to store your uploaded documents using OpenSign\u2122","source":"@site/docs/self-host/cloud-storage/s3.md","sourceDirName":"self-host/cloud-storage","slug":"/self-host/cloud-storage/s3","permalink":"/docs/self-host/cloud-storage/s3","draft":false,"unlisted":false,"editUrl":"https://github.com/opensignlabs/opensign/tree/feat-docs/docs/docs/self-host/cloud-storage/s3.md","tags":[],"version":"current","frontMatter":{"title":"AWS S3"},"sidebar":"selfhostSidebar","previous":{"title":"Cloud Storage","permalink":"/docs/category/cloud-storage"},"next":{"title":"Guides","permalink":"/docs/category/guides"}}');var c=t(74848),i=t(28453);const o={title:"AWS S3"},a=void 0,r={},l=[{value:"You can create an AWS S3 bucket to store your uploaded documents using OpenSign\u2122",id:"you-can-create-an-aws-s3-bucket-to-store-your-uploaded-documents-using-opensign",level:2},{value:"AWS S3 -",id:"aws-s3--",level:3}];function h(e){const s={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",p:"p",pre:"pre",strong:"strong",ul:"ul",...(0,i.R)(),...e.components};return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(s.h2,{id:"you-can-create-an-aws-s3-bucket-to-store-your-uploaded-documents-using-opensign",children:"You can create an AWS S3 bucket to store your uploaded documents using OpenSign\u2122"}),"\n",(0,c.jsx)(s.h3,{id:"aws-s3--",children:"AWS S3 -"}),"\n",(0,c.jsxs)(s.ul,{children:["\n",(0,c.jsxs)(s.li,{children:["\n",(0,c.jsx)(s.p,{children:(0,c.jsx)(s.strong,{children:"Step 1 : Create a S3 bucket"})}),"\n",(0,c.jsxs)(s.ul,{children:["\n",(0,c.jsxs)(s.li,{children:["Login to ",(0,c.jsx)(s.a,{href:"https://aws.amazon.com/console/",children:"AWS console"})]}),"\n",(0,c.jsxs)(s.li,{children:["Navigate to S3 under services.\n",(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/1a734349-1c1a-4f53-8582-7318c22911f5",alt:"Screenshot 2024-09-30 203247"})]}),"\n",(0,c.jsxs)(s.li,{children:['Hit "Create Bucket" button on upper right corner.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/b036fa3b-20c4-4348-8697-68bcf2fd9de3",alt:"Screenshot 2024-09-30 195246"})]}),"\n",(0,c.jsxs)(s.li,{children:['Now provide bucket name and don\'t change any other options scroll down and click on "Create Bucket" button.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/3fb1a591-fffd-4703-9b1f-9cb1edbdf7fe",alt:"Screenshot 2024-09-30 195603"}),"\n",(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/a0b2be8a-a273-474d-88d5-614cb42de8dd",alt:"Screenshot 2024-09-30 195835"})]}),"\n",(0,c.jsx)(s.li,{children:"Click on name of bucket from list which we have just created."}),"\n",(0,c.jsxs)(s.li,{children:["Now go to permission Tab and scroll down to bottom.\n",(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/dbf44b05-370b-40f8-bfc1-fd2f8441da46",alt:"Screenshot 2024-09-30 202035"})]}),"\n",(0,c.jsxs)(s.li,{children:['At the bottom you will see cross-origin resource sharign (cors) section click on "Edit" button.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/a9fb13b3-7a30-4c49-b3ea-6a30a2b7c357",alt:"Screenshot 2024-09-30 202057"})]}),"\n",(0,c.jsxs)(s.li,{children:['Now paste below line of code and add origin url in AllowedOrigins array and click on "Save changes".',"\n",(0,c.jsx)(s.pre,{children:(0,c.jsx)(s.code,{children:'[\n {\n "AllowedHeaders": [\n "*"\n ],\n "AllowedMethods": [\n "GET",\n "PUT",\n "POST"\n ],\n "AllowedOrigins": [\n "https://localhost:3001",\n "https://app.opensignlabs.com",\n"https://eu-app.opensignlabs.com"\n ],\n "ExposeHeaders": [\n "x-amz-server-side-encryption",\n "x-amz-request-id",\n "x-amz-id-2"\n ],\n "MaxAgeSeconds": 3000\n }\n]\n'})}),"\n"]}),"\n",(0,c.jsx)(s.li,{children:'Once completed, navigate to "Properties," where you\'ll find the bucket region (e.g., us-east-1).'}),"\n",(0,c.jsx)(s.li,{children:'Set the bucket name you created in step 1 as the value for "DO_SPACE" in the ENV file.'}),"\n",(0,c.jsx)(s.li,{children:'Assign the region value to the "DO_REGION" variable in the ENV file.'}),"\n",(0,c.jsx)(s.li,{children:'Replace the region in the URL s3.region.amazonaws.com and set it as "DO_ENDPOINT" in the ENV file.'}),"\n",(0,c.jsxs)(s.li,{children:["Replace both the bucket name and region in the URL ",(0,c.jsx)(s.a,{href:"https://bucketName.s3.region.amazonaws.com",children:"https://bucketName.s3.region.amazonaws.com"}),' and set it as "DO_BASEURL" in the ENV file.']}),"\n"]}),"\n"]}),"\n",(0,c.jsxs)(s.li,{children:["\n",(0,c.jsx)(s.p,{children:(0,c.jsx)(s.strong,{children:"Step 2 : Create a aws policy"})}),"\n",(0,c.jsxs)(s.ul,{children:["\n",(0,c.jsxs)(s.li,{children:["Navigate to IAM under services\n",(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/8109d2bb-1afb-4407-b5cd-4886a070d5cc",alt:"Screenshot 2024-09-30 200247"})]}),"\n",(0,c.jsx)(s.li,{children:'Now click on "Polices" from left side "access management" menu.'}),"\n",(0,c.jsxs)(s.li,{children:['Hit "Create Policy" button on upper right corner.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/1b3b5608-9a84-477d-b46e-aaf884a73343",alt:"Screenshot 2024-09-30 200939"})]}),"\n",(0,c.jsxs)(s.li,{children:['Search for S3 and Tick "PutObject" and "GetObject" from "Specify permissions" screen.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/7168d261-abc4-4789-8e64-628c81c79e24",alt:"Screenshot 2024-09-30 200537"}),"\n",(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/863f8e7c-74eb-4f1b-9ea5-41524ba249ca",alt:"Screenshot 2024-09-30 200607"})]}),"\n",(0,c.jsxs)(s.li,{children:['Select "All" under Resources\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/c4b26336-aab0-49c3-a817-d2a71d603091",alt:"Screenshot 2024-09-30 200929"})]}),"\n",(0,c.jsxs)(s.li,{children:["provide policy name and hit on 'Create Policy\".\n",(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/4db2ab95-14bb-4ea1-a9a3-821e20e70038",alt:"Screenshot 2024-09-30 200808"})]}),"\n"]}),"\n"]}),"\n",(0,c.jsxs)(s.li,{children:["\n",(0,c.jsx)(s.p,{children:"Step 3 : Create IAM user."}),"\n",(0,c.jsxs)(s.ul,{children:["\n",(0,c.jsxs)(s.li,{children:['Now click on "Users" from left side "access management" menu and then click on "Create User" button.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/1aa1f071-6291-457f-a514-970f511866cb",alt:"Screenshot 2024-09-30 201026"})]}),"\n",(0,c.jsx)(s.li,{children:"Provide username and click on Next button."}),"\n",(0,c.jsxs)(s.li,{children:['Now select "Attach policies directly" from Permissions options.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/13c6d571-d3da-4259-8f04-8ec130d9091a",alt:"Screenshot 2024-09-30 201731"})]}),"\n",(0,c.jsxs)(s.li,{children:['Now, search for the policy we created in the previous step within the "Permissions Policies" section.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/c2b1643d-e3e3-49ee-920b-641e7ff819f5",alt:"Screenshot 2024-09-30 201742"})]}),"\n",(0,c.jsx)(s.li,{children:'Now scroll down and Click on "Create User" Button.'}),"\n"]}),"\n"]}),"\n",(0,c.jsxs)(s.li,{children:["\n",(0,c.jsx)(s.p,{children:"Step 4 : Generate Credentials"}),"\n",(0,c.jsxs)(s.ul,{children:["\n",(0,c.jsx)(s.li,{children:"Now Click on username form list which we have created in previous step."}),"\n",(0,c.jsx)(s.li,{children:'Navigate to "Security credentials".'}),"\n",(0,c.jsxs)(s.li,{children:['Click on "Create Access Key" from right corner.\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/d25abe2f-0cfc-4cc0-a02c-6b9fc6559dd2",alt:"Screenshot 2024-09-30 201850"})]}),"\n",(0,c.jsxs)(s.li,{children:['In the next step select "Application running outside AWS".\n',(0,c.jsx)(s.img,{src:"https://github.com/user-attachments/assets/f9b0cdb2-3718-4ae6-a4ba-68e144d1f4a1",alt:"Screenshot 2024-09-30 201917"})]}),"\n",(0,c.jsx)(s.li,{children:'In the next step, you will see the "Access key" and "Secret Access key." Copy both values.'}),"\n",(0,c.jsx)(s.li,{children:'Assign the "Access key" value to the "DO_ACCESS_KEY_ID" environment variable.'}),"\n",(0,c.jsx)(s.li,{children:'Assign the "Secret Access key" value to the "DO_SECRET_ACCESS_KEY" environment variable.'}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,c.jsxs)(s.p,{children:["If you encounter any issues while following these instructions, refer to the link below: - ",(0,c.jsx)(s.a,{href:"https://repost.aws/knowledge-center/create-access-key",children:"https://repost.aws/knowledge-center/create-access-key"})]})]})}function d(e={}){const{wrapper:s}={...(0,i.R)(),...e.components};return s?(0,c.jsx)(s,{...e,children:(0,c.jsx)(h,{...e})}):h(e)}},28453(e,s,t){t.d(s,{R:()=>o,x:()=>a});var n=t(96540);const c={},i=n.createContext(c);function o(e){const s=n.useContext(i);return n.useMemo(function(){return"function"==typeof e?e(s):{...s,...e}},[s,e])}function a(e){let s;return s=e.disableParentContext?"function"==typeof e.components?e.components(c):e.components||c:o(e.components),n.createElement(i.Provider,{value:s},e.children)}}}]); |