You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+61-5
Original file line number
Diff line number
Diff line change
@@ -4,9 +4,65 @@ The Backblaze Custom Action for Frame.io allows you to quickly move data between
4
4
5
5

6
6
7
-
The root directory of the backblaze-frameio GitHub repository contains two directories corresponding to different deployment options, plus directories containing common code and a test client:
7
+
The container should run on any container platform. We leverage the container platform to handle TLS termination. If you want to expose the container directly we **strongly** recommend you implement TLS within the app code directly.
-[backblaze-frameio-common](backblaze-frameio-common) - common code to interact with Frame.io, B2
12
-
-[test-client](test-client) - test client to emulate Frame.io sending custom action requests
9
+
## Create a Bucket in Backblaze B2
10
+
11
+
-[Sign up](https://www.backblaze.com/b2/sign-up.html?referrer=nopref) for a Backblaze account if you do not already have one.
12
+
- Sign in to the web console.
13
+
- Click **Buckets** under **B2 Cloud Storage** in the navigation menu on the left, then click **Create a Bucket**.
14
+
- Enter a bucket name; leave the rest of the settings with their defaults. Note that bucket names must be globally unique. It may take a couple of tries to find an unused bucket name.
15
+
- Click **Create a Bucket**.
16
+
17
+
## Create an Application Key in Backblaze B2
18
+
19
+
- Still in the Backblaze web console, click **App Keys** under **Account** in the left nav menu, then click **Add a New Application Key**.
20
+
- Supply a key name (key names need not be globally unique).
21
+
- Click the dropdown by **Allow access to Bucket(s):** and select the bucket you created in the previous step. Leave the rest of the settings with their defaults.
22
+
- Click **Create New Key**.
23
+
-**IMPORTANT**: make a note of the key ID and application key before leaving this page. You will not be able to go back and retrieve the application key later!
24
+
25
+
## Create a Custom Action in Frame.io
26
+
27
+
Login to the [Frame.io Developer Site](https://developer.frame.io/) and create a custom action (Developer Tools > Custom Actions > Create a Custom Action):
28
+
29
+
- NAME: Backblaze B2
30
+
- DESCRIPTION: Import or export assets and projects to Backblaze B2
31
+
- EVENT: import-export
32
+
- URL: *Set this to your container's endpoint*
33
+
- TEAM: Select your team
34
+
- ACCESS: Enable if you wish collaborators to have access to the custom action.
35
+
36
+
## Create a Token in Frame.io
37
+
38
+
Still in the Frame.io Developer Site, create a token (Developer Tools > Tokens > Create a Token). Provide a suitable token description, enable the **Create** and **Read** scopes under **Assets**, and click **Submit**.
39
+
40
+
## Configure the Container Environment
41
+
42
+
You need to set the following environment variables in the container environment. The easiest way to do this is to create a `.env` file.
43
+
44
+
-`FRAMEIO_TOKEN` = The Frame.io developer **token** you obtain from https://developer.frame.io/app/tokens
45
+
-`FRAMEIO_SECRET` = the Frame.io Custom Action **secret** you obtain from https://developer.frame.io/app/custom-actions
46
+
-`BUCKET_ENDPOINT` = Your Backblaze B2 S3-compatible endpoint, in the form `https://s3.REGION.backblazeb2.com`
47
+
-`BUCKET_NAME` = Your Backblaze B2 bucket name
48
+
-`ACCESS_KEY` = Your Backblaze B2 access key - it is strongly recommended this is unique for this app
49
+
-`SECRET_KEY` = Your Backblaze B2 secret key - it is strongly recommended this is unique for this app
50
+
-`UPLOAD_PATH` = Path in Backblaze B2 for exports, for example `fio_exports`
51
+
-`DOWNLOAD_PATH` = Folder in Frame.io for imports, for example `b2_imports`
52
+
53
+
## Build and Start the Container
54
+
55
+
To build the Docker image:
56
+
57
+
```bash
58
+
docker build . -t backblaze-frameio
59
+
```
60
+
61
+
Docker responds with an image id. Start a container in daemon mode, listening on port 8888, with the `.env` file you created and the image ID:
62
+
```bash
63
+
docker run -d -p 8888:8888 --env-file .env backblaze-frameio
64
+
```
65
+
66
+
## Test the Web Service with the Test Client
67
+
68
+
Follow the instructions in the [test-client](test-client/) directory.
0 commit comments