-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: karthik2804 <karthik.ganeshram@fermyon.com>
- Loading branch information
1 parent
b75c9a5
commit fe11981
Showing
10 changed files
with
3,930 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
node_modules | ||
dist | ||
target | ||
.spin/ | ||
dist.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# Backblaze B2 Integration | ||
|
||
This example showcases how to connect to and send messages using Backblaze B2 with the AWS SDK. | ||
|
||
## Prerequisites | ||
- `spin >=2.6.0` | ||
- | ||
|
||
## Install Dependencies | ||
Install the necessary npm packages: | ||
|
||
```bash | ||
npm install | ||
``` | ||
|
||
## Setup the Example | ||
|
||
1. **Create an AWS Account** | ||
- If you don't have an Backblaze account, create one at [Backblaze](https://www.backblaze.com/). | ||
|
||
2. **Get Backblaze Credentials** | ||
- Create or obtain your Backblaze credentials (Access Key ID, Secret Access Key). | ||
|
||
3. **Configure the Code** | ||
- Copy the region, access key ID, secret access key, into the code at `src/index.ts`. | ||
|
||
```typescript | ||
const client = new SQSClient({ | ||
endpoint: "<backblaze b2 endpoint" | ||
region: "<region>", | ||
credentials: { | ||
accessKeyId: "<accessKeyId>", | ||
secretAccessKey: "<secretAccessKey>", | ||
}, | ||
}); | ||
``` | ||
|
||
## Building and Running the Example | ||
|
||
```bash | ||
spin build | ||
spin up | ||
``` | ||
|
||
Use e.g. curl -v http://127.0.0.1:3000/ to test the endpoint. |
Oops, something went wrong.