Linode Object Storage

250 GB storage + 1 TB Outbound Transfer for $5/mo.

Linode Object Storage is a good choice if you’re already using Linode to host your server. It should be fast to transfer your video from your server to their storage service, and their pricing will probably just be the flat $5/mo for you, so it’s easy to know what you’re paying.

  • Create a new bucket at the Linode Object Storage admin page.
  • Make sure CORS is enabled on your new bucket.
  • In the Owncast Addmin change the S3 endpoint to match the hostname listed below your newly created bucket that looks something like us-east-1.linodeobjects.com, the bucket name to match the one you just created and the S3 region to match the us-east-1 equivalent of the above hostname.
  • Using the Linode Object Access Keys page create a new Access Key and add the Key and Secret in the admin.

In the following steps Linode requires you to interact with your bucket using the s3cmd tool. So install that on your terminal and configure it.

Run s3cmd --configure and fill in the values with what is currently in your config file. It should look similar to this:

Access Key: ABC12334
Secret Key: fj3kd83jdkh
Default Region: US
S3 Endpoint: us-east-1.linodeobjects.com
DNS-style bucket+hostname:port template for accessing a bucket: us-east-1.linodeobjects.com
Use HTTPS protocol: False

Add permissions to access video.

This part sucks. But you only have to do it once per bucket. These are the full instructions but let me summarize.

  1. Create a file called bucket_policy.json that has the following:

    {
    "Statement": [
    {
    "Effect": "Allow",
    "Principal": {
    "AWS": [
    "*"
    ]
    },
    "Action": [
    "s3:GetObject"
    ],
    "Resource": [
    "arn:aws:s3::MYBUCKETNAME/*"
    ]
    }
    ]
    }

  2. Replace MYBUCKETNAME with your actual bucket name.

  3. Run s3cmd setpolicy bucket_policy.json s3://MYBUCKETNAME replacing MYBUCKETNAME with your bucket name.

  4. Run s3cmd info s3://MYBUCKETNAME to make sure the new policy saved.

Now files video saved to Linode Object Storage will be readable.

More details about how to get started using Linode Object Storage can be found on their documentation.

File expiration

Make files older than one day expire and delete themselves so you don’t pay for storage of old video.

Full details are in their documentation.

Create a file called lifecycle_policy.xml with the following contents:

<LifecycleConfiguration>
<Rule>
<ID>delete-all-objects</ID>
<Prefix></Prefix>
<Status>Enabled</Status>
<Expiration>
<Days>1</Days>
</Expiration>
</Rule>
</LifecycleConfiguration>
  • Run s3cmd setlifecycle lifecycle_policy.xml s3://MYBUCKETNAME.
  • Run s3cmd info s3://MYBUCKETNAME and you should now see Expiration Rule: all objects in this bucket will expire in '1' day(s) after creation.