Peertube and S3/Minio Objectstorage
-
@scooke Try unsetting
base_url
and see if that works. I think base_url is for CDN setups which requires additional configuration - https://docs.joinpeertube.org/admin-remote-storage?id=cache-server . In a CDN setup, the video is served to the browser straight from minio (as opposed to browser -> peertube -> minio).wrote on Jun 22, 2022, 9:43 PM last edited by@girish Holy smokes. That did it. I just # commented out those two base_url lines, restarted the app, and now the upload works, and the download.
Now, I thought I had reached a similar point before, but I think what I had missed was copying the new cert to the proper directory. Thus, it wasn't working.
Now, it is. You sir are a magician.
-
@scooke
iam already try using contabo. it's does not work. contabo not support virtual host style, sorry for my bad english.
its my working config. insert after storage section.
if have an error you can check the logs from peertube administration. make sure minio support virtual host style requests
https://github.com/Chocobozzz/PeerTube/issues/4455
example vhost style like this : yourbucket.sin1.contabostorage.com
path style : sin1.contabostorage.com/a808f6dce2514fba8eeb68596724ddd1:yourbucketobject_storage: enabled: true # Without protocol, will default to HTTPS endpoint: 'e4u6.la11.idrivee2-5.com' # 's3.amazonaws.com' or 's3.fr-par.scw.cloud' for example region: 'us-la' # Set this ACL on each uploaded object upload_acl: '' credentials: # You can also use AWS_ACCESS_KEY_ID env variable access_key_id: 'secret' # You can also use AWS_SECRET_ACCESS_KEY env variable secret_access_key: 'secret' # Maximum amount to upload in one request to object storage max_upload_part: 2GB streaming_playlists: bucket_name: 'peertube' # Allows setting all buckets to the same value but with a different prefix prefix: 'streaming-playlists/' # Example: 'streaming-playlists:' # Base url for object URL generation, scheme and host will be replaced by this URL # Useful when you want to use a CDN/external proxy base_url: 'https://peertube.e4u6.la11.idrivee2-5.com' # Example: '' # Same settings but for webtorrent videos videos: bucket_name: 'peertube' prefix: 'videos/' base_url: 'https://peertube.e4u6.la11.idrivee2-5.com'
wrote on Jan 21, 2023, 2:13 AM last edited by jdaviescoates Jan 21, 2023, 2:18 AM@awnzky said in Peertube and S3/Minio Objectstorage:
iam already try using contabo. it's does not work.
Wish I'd read/ seen this earlier. I just spent hours pulling my hair trying to get contabo object storage to work with peertube but I just couldn't get it to work either
(whereas on Scaleway it Just Worked - and even when it didn't work, like when I hadn't set the region, it gave useful error messages telling me what was wrong and how to fix it
)
However, even with the S3 connection to my Scaleway object buckets working fine, playback actually just didn't work
Playback with Object Storage disabled works fine.
I don't have any base_url set anywhere.
-
@awnzky said in Peertube and S3/Minio Objectstorage:
iam already try using contabo. it's does not work.
Wish I'd read/ seen this earlier. I just spent hours pulling my hair trying to get contabo object storage to work with peertube but I just couldn't get it to work either
(whereas on Scaleway it Just Worked - and even when it didn't work, like when I hadn't set the region, it gave useful error messages telling me what was wrong and how to fix it
)
However, even with the S3 connection to my Scaleway object buckets working fine, playback actually just didn't work
Playback with Object Storage disabled works fine.
I don't have any base_url set anywhere.
wrote on Jan 21, 2023, 2:28 AM last edited by@jdaviescoates playback may require the bucket to be https accessible, which is a setting.
-
@jdaviescoates playback may require the bucket to be https accessible, which is a setting.
wrote on Jan 21, 2023, 10:15 AM last edited by@robi said in Peertube and S3/Minio Objectstorage:
@jdaviescoates playback may require the bucket to be https accessible, which is a setting.
You mean making the bucket public? Already is. Can't find any other settings related to https.
-
@robi said in Peertube and S3/Minio Objectstorage:
@jdaviescoates playback may require the bucket to be https accessible, which is a setting.
You mean making the bucket public? Already is. Can't find any other settings related to https.
wrote on Jan 21, 2023, 12:07 PM last edited by@jdaviescoates I wonder if the problem is the TYPE of bucket. In the comments above I was running a self-installed instance of Minio. That is, I didn't use Yunohost, or CapRover, or Cloudron, etc. I installed it by hand. Somehow (I guess I could figure it out by rereading the above) I set Minio up to use virtual-host, rather than path-style. And for whatever reason, Peertube (only) works with virtual-host style. Maybe this has something to do with it?
FWIW (I'm only getting my own head sort of around all this), the end_point in teh config has to be whatever your API enpoint is. Off the top of my head, I forget how to tell which is which, but one address is the home adress, and the other is the end point address. That is to say, when it is being installed on mino.example.com, a second API address is created, something like minio-s3.example.com. The API is the address needed.
-
@jdaviescoates I wonder if the problem is the TYPE of bucket. In the comments above I was running a self-installed instance of Minio. That is, I didn't use Yunohost, or CapRover, or Cloudron, etc. I installed it by hand. Somehow (I guess I could figure it out by rereading the above) I set Minio up to use virtual-host, rather than path-style. And for whatever reason, Peertube (only) works with virtual-host style. Maybe this has something to do with it?
FWIW (I'm only getting my own head sort of around all this), the end_point in teh config has to be whatever your API enpoint is. Off the top of my head, I forget how to tell which is which, but one address is the home adress, and the other is the end point address. That is to say, when it is being installed on mino.example.com, a second API address is created, something like minio-s3.example.com. The API is the address needed.
wrote on Jan 21, 2023, 2:06 PM last edited by@scooke said in Peertube and S3/Minio Objectstorage:
Maybe this has something to do with it?
That's why Contabo didn't work, I think.
But Scaleway does support that and did work in that the files get transferred to the bucket fine. It's just that then playback basically doesn't work at all.
-
@scooke said in Peertube and S3/Minio Objectstorage:
Maybe this has something to do with it?
That's why Contabo didn't work, I think.
But Scaleway does support that and did work in that the files get transferred to the bucket fine. It's just that then playback basically doesn't work at all.
wrote on Jan 21, 2023, 2:13 PM last edited by@jdaviescoates Care to share your config (the pertinent part)?
-
@jdaviescoates Care to share your config (the pertinent part)?
wrote on Jan 21, 2023, 2:30 PM last edited by# Store all videos in one bucket on Scaleway object_storage: enabled: true # Scaleway endpoint endpoint: 's3.fr-par.scw.cloud' region: 'fr-par' videos: bucket_name: 'bridport-tv' prefix: 'videos/' # Use the same bucket as for webtorrent videos but with a different prefix streaming_playlists: bucket_name: 'bridport-tv' prefix: 'streaming-playlists/' credentials: access_key_id: 'xxxxx' secret_access_key: 'xxxxx'
That's was working fine for getting stuff into the bucket, but then videos didn't actually play
Bucket is also public:
-
# Store all videos in one bucket on Scaleway object_storage: enabled: true # Scaleway endpoint endpoint: 's3.fr-par.scw.cloud' region: 'fr-par' videos: bucket_name: 'bridport-tv' prefix: 'videos/' # Use the same bucket as for webtorrent videos but with a different prefix streaming_playlists: bucket_name: 'bridport-tv' prefix: 'streaming-playlists/' credentials: access_key_id: 'xxxxx' secret_access_key: 'xxxxx'
That's was working fine for getting stuff into the bucket, but then videos didn't actually play
Bucket is also public:
wrote on Jan 21, 2023, 2:33 PM last edited by@jdaviescoates if you get a public link, does it play in the browser?
compare that to the link the app tries to use?
-
@jdaviescoates if you get a public link, does it play in the browser?
compare that to the link the app tries to use?
wrote on Jan 21, 2023, 2:58 PM last edited by@robi said in Peertube and S3/Minio Objectstorage:
@jdaviescoates if you get a public link, does it play in the browser?
Yes
-
@jdaviescoates if you get a public link, does it play in the browser?
compare that to the link the app tries to use?
wrote on Jan 21, 2023, 3:04 PM last edited by@robi said in Peertube and S3/Minio Objectstorage:
compare that to the link the app tries to use?
Looking for that I spotted this:
CORS Missing Allowed Origin
I guess that's likely the problem...
(man, it's SO much easier doing this stuff when I'm not both freezing cold and way too tired! /me reminds himself, again, to get more f-ing sleep and go to bed on f-ing time!)
-
@robi said in Peertube and S3/Minio Objectstorage:
compare that to the link the app tries to use?
Looking for that I spotted this:
CORS Missing Allowed Origin
I guess that's likely the problem...
(man, it's SO much easier doing this stuff when I'm not both freezing cold and way too tired! /me reminds himself, again, to get more f-ing sleep and go to bed on f-ing time!)
wrote on Jan 21, 2023, 3:23 PM last edited byWoohoo!
So, after following this guide:
https://www.scaleway.com/en/docs/storage/object/api-cli/object-storage-aws-cli/
And then this guide:
https://www.scaleway.com/en/docs/storage/object/api-cli/setting-cors-rules/
I now have videos stored on S3 that ALSO play!
-
Woohoo!
So, after following this guide:
https://www.scaleway.com/en/docs/storage/object/api-cli/object-storage-aws-cli/
And then this guide:
https://www.scaleway.com/en/docs/storage/object/api-cli/setting-cors-rules/
I now have videos stored on S3 that ALSO play!
wrote on Jan 21, 2023, 3:29 PM last edited by jdaviescoates Jan 21, 2023, 8:23 PMScaleway are great. Good prices, great docs!
I was tempted by special offer Contabo pricing, but unlike Scaleway they aren't 100% renewably powered (although their German based stuff when I'd bought some object storage is), and their docs are crap.
So looks like I'll just ditch Contabo and stick with using Scaleway for my Object Storage needs.
-
wrote on Jan 27, 2023, 12:03 AM last edited by
anyone done this on Linode?
-
I recently discovered how to host media from my Cloudron-hosted Mastodon instance on my Minio instance (non-Cloudron), and it works great. So I started exploring what else I can use my Minio storage for, and found a plugin for Wordpress, , that also works well. So now, I'm trying to see how to use it for Peertube, which apparently can use objectstorage. I've found the following links with sample yaml files, but I haven't been able to get it working on my own Cloudron-hosted Peertube instance. Has anyone else had success?
https://docs.joinpeertube.org/admin-remote-storage
https://framacolibri.org/t/redundancy-videos-not-able-to-use-object-storage/14668
https://github.com/Chocobozzz/PeerTube/blob/develop/config/production.yaml.example
https://github.com/Chocobozzz/PeerTube/blob/develop/support/docker/production/config/production.yaml
wrote on Mar 10, 2023, 12:00 PM last edited by LoudLemur Mar 10, 2023, 12:00 PM@scooke Thanks for asking this question. I might try this using block storage with Wasabi and PeerTube.
Why is object storage suitable for this task? Isn't object storage better for keeping gigantic files? I suppose a considerable archive of videos would end up needing a large amount of storage, but they would all be separate files.
-
@scooke Thanks for asking this question. I might try this using block storage with Wasabi and PeerTube.
Why is object storage suitable for this task? Isn't object storage better for keeping gigantic files? I suppose a considerable archive of videos would end up needing a large amount of storage, but they would all be separate files.
wrote on Mar 10, 2023, 1:07 PM last edited by@LoudLemur said in Peertube and S3/Minio Objectstorage:
Why is object storage suitable for this task? Isn't object storage better for keeping gigantic files?
Video files are relatively large files.
But aside from that, often VPS servers don't come with much disk space and so Object Storage is just one relatively cheap way of increasing the amount of storage you have.
@LoudLemur said in Peertube and S3/Minio Objectstorage:
Wasabi
Lots of people on here seem to have moved away from them for various reasons.
The cheapest out there seems to be iDrive e2 who have a 90% off offer which makes it insanely cheap for the first year (and pretty good value after that):
Personally I use Scaleway who are also good value and 100% powered by renewable energy
I've got all my instances of Peertube, Mastodon, and Pixelfed all storing their data on Scaleway Object Storage.
-
@LoudLemur said in Peertube and S3/Minio Objectstorage:
Why is object storage suitable for this task? Isn't object storage better for keeping gigantic files?
Video files are relatively large files.
But aside from that, often VPS servers don't come with much disk space and so Object Storage is just one relatively cheap way of increasing the amount of storage you have.
@LoudLemur said in Peertube and S3/Minio Objectstorage:
Wasabi
Lots of people on here seem to have moved away from them for various reasons.
The cheapest out there seems to be iDrive e2 who have a 90% off offer which makes it insanely cheap for the first year (and pretty good value after that):
Personally I use Scaleway who are also good value and 100% powered by renewable energy
I've got all my instances of Peertube, Mastodon, and Pixelfed all storing their data on Scaleway Object Storage.
wrote on Mar 10, 2023, 1:09 PM last edited by@jdaviescoates You are so good to me!
Thank you. I shall look into those. -
wrote on Oct 6, 2023, 2:24 PM last edited by benborges Oct 6, 2023, 2:26 PM
I'm wondering if there is a path to do this with Peertube + Hetzner storage box or if the S3 Storage objects way is the only way to store peertube video content outside the cloudron, anyone tried ?
edit : Hmm apparently, the answer is no, only S3 is supported : https://docs.joinpeertube.org/maintain/remote-storage#migrate-to-another-object-storage-provider
-
I'm wondering if there is a path to do this with Peertube + Hetzner storage box or if the S3 Storage objects way is the only way to store peertube video content outside the cloudron, anyone tried ?
edit : Hmm apparently, the answer is no, only S3 is supported : https://docs.joinpeertube.org/maintain/remote-storage#migrate-to-another-object-storage-provider
wrote on Oct 6, 2023, 2:36 PM last edited by@benborges said in Peertube and S3/Minio Objectstorage:
I'm wondering if there is a path to do this with Peertube + Hetzner storage box or if the S3 Storage objects way is the only way to store peertube video content outside the cloudron, anyone tried ?
You might be able to mount a Volume and then use that for the data directory?
-
@benborges said in Peertube and S3/Minio Objectstorage:
I'm wondering if there is a path to do this with Peertube + Hetzner storage box or if the S3 Storage objects way is the only way to store peertube video content outside the cloudron, anyone tried ?
You might be able to mount a Volume and then use that for the data directory?
wrote on Oct 6, 2023, 4:12 PM last edited by benborges Oct 6, 2023, 4:12 PM