f6d6e7f861
* WIP: resumable video uploads relates to #324 * fix review comments * video upload: error handling * fix audio upload * fixes after self review * Update server/controllers/api/videos/index.ts Co-authored-by: Rigel Kent <par@rigelk.eu> * Update server/middlewares/validators/videos/videos.ts Co-authored-by: Rigel Kent <par@rigelk.eu> * Update server/controllers/api/videos/index.ts Co-authored-by: Rigel Kent <par@rigelk.eu> * update after code review * refactor upload route - restore multipart upload route - move resumable to dedicated upload-resumable route - move checks to middleware - do not leak internal fs structure in response * fix yarn.lock upon rebase * factorize addVideo for reuse in both endpoints * add resumable upload API to openapi spec * add initial test and test helper for resumable upload * typings for videoAddResumable middleware * avoid including aws and google packages via node-uploadx, by only including uploadx/core * rename ex-isAudioBg to more explicit name mentioning it is a preview file for audio * add video-upload-tmp-folder-cleaner job * stronger typing of video upload middleware * reduce dependency to @uploadx/core * add audio upload test * refactor resumable uploads cleanup from job to scheduler * refactor resumable uploads scheduler to compare to last execution time * make resumable upload validator to always cleanup on failure * move legacy upload request building outside of uploadVideo test helper * filter upload-resumable middlewares down to POST, PUT, DELETE also begin to type metadata * merge add duration functions * stronger typings and documentation for uploadx behaviour, move init validator up * refactor(client/video-edit): options > uploadxOptions * refactor(client/video-edit): remove obsolete else * scheduler/remove-dangling-resum: rename tag * refactor(server/video): add UploadVideoFiles type * refactor(mw/validators): restructure eslint disable * refactor(mw/validators/videos): rename import * refactor(client/vid-upload): rename html elem id * refactor(sched/remove-dangl): move fn to method * refactor(mw/async): add method typing * refactor(mw/vali/video): double quote > single * refactor(server/upload-resum): express use > all * proper http methud enum server/middlewares/async.ts * properly type http methods * factorize common video upload validation steps * add check for maximum partially uploaded file size * fix audioBg use * fix extname(filename) in addVideo * document parameters for uploadx's resumable protocol * clear META files in scheduler * last audio refactor before cramming preview in the initial POST form data * refactor as mulitpart/form-data initial post request this allows preview/thumbnail uploads alongside the initial request, and cleans up the upload form * Add more tests for resumable uploads * Refactor remove dangling resumable uploads * Prepare changelog * Add more resumable upload tests * Remove user quota check for resumable uploads * Fix upload error handler * Update nginx template for upload-resumable * Cleanup comment * Remove unused express methods * Prefer to use got instead of raw http * Don't retry on error 500 Co-authored-by: Rigel Kent <par@rigelk.eu> Co-authored-by: Rigel Kent <sendmemail@rigelk.eu> Co-authored-by: Chocobozzz <me@florianbigard.com> |
||
---|---|---|
.github | ||
client | ||
config | ||
scripts | ||
server | ||
shared | ||
support | ||
.dockerignore | ||
.editorconfig | ||
.eslintrc.json | ||
.gitignore | ||
.gitlab-ci.yml | ||
.gitpod.yml | ||
CHANGELOG.md | ||
CODE_OF_CONDUCT.md | ||
CREDITS.md | ||
engines.yaml | ||
FAQ.md | ||
LICENSE | ||
package.json | ||
README.md | ||
SECURITY.md | ||
server.ts | ||
tsconfig.json | ||
yarn.lock |
Website | Join an instance | Create an instance | Chat with us | Donate
Be part of a network of multiple small federated, interoperable video hosting providers. Follow video creators and create videos. No vendor lock-in. All on a platform that is community-owned and ad-free.
Developed with ❤ by Framasoft
Introduction
PeerTube is a free, decentralized and federated video platform developed as an alternative to other platforms that centralize our data and attention, such as YouTube, Dailymotion or Vimeo. 🎬
But one organization hosting PeerTube alone may not have enough money to pay for bandwidth and video storage of its servers, all servers of PeerTube are interoperable as a federated network, and non-PeerTube servers can be part of the larger Vidiverse (federated video network) by talking our implementation of ActivityPub. Video load is reduced thanks to P2P in the web browser using WebTorrent or p2p-media-loader.
To learn more, see:
- This two-minute video (hosted on PeerTube) explaining what PeerTube is and how it works
- PeerTube's project homepage, joinpeertube.org
- Demonstration instances:
- This video demonstrating the communication between PeerTube and Mastodon (a decentralized Twitter alternative)
✨ Features
Video streaming, even in live!
Just upload your videos, and be sure they will stream anywhere. Add a description, some tags and your video will be discoverable by the entire video fediverse, not just your instance. You can even embed a player on your favorite website!
You are used to hosting live events? We got you covered too! Start livestreaming from your favorite client, and even host permanent streams!
Keep in touch with video creators
Follow your favorite channels from PeerTube or really any other place. No need to have an account on the instance you watched a video to follow its author, you can do all of that from the Fediverse (Mastodon, Pleroma, and plenty others), or just with good ol' RSS.
An interface to call home
Be it as a user or an instance administrator, you can decide what your experience will be like. Don't like the colors? They are easy to change. Don't want to list videos of an instance but let your users subscribe to them? Don't like the regular web client? All of that can be changed, and much more. No UX dark pattern, no mining your data, no video recommendation bullshit™.
Communities that help each other
In addition to visitors using WebTorrent to share the load among them, instances can help each other by caching one another's videos. This way even small instances have a way to show content to a wider audience, as they will be shouldered by friend instances (more about that in our redundancy guide).
Content creators can get help from their viewers in the simplest way possible: a support button showing a message linking to their donation accounts or really anything else. No more pay-per-view and advertisements that hurt visitors and incentivize alter creativity (more about that in our FAQ).
🙌 Contributing
You don't need to be a programmer to help!
You can give us your feedback, report bugs, help us translate PeerTube, write documentation, and more. Check out the contributing guide to know how, it takes less than 2 minutes to get started. 😉
You can also join the cheerful bunch that makes our community:
- Chat:
- IRC : #peertube on chat.freenode.net:6697
- Matrix (bridged on IRC and Discord) : #peertube:matrix.org
- Forum:
- Framacolibri: https://framacolibri.org/c/peertube
Feel free to reach out if you have any questions or ideas! 💬
📦 Create your own instance
See the production guide, which is the recommended way to install or upgrade PeerTube. For hardware requirements, see Should I have a big server to run PeerTube? in the FAQ.
See the community packages, which cover various platforms (including YunoHost and Docker).
📖 Documentation
If you have a question, please try to find the answer in the FAQ first.
User documentation
See the user documentation.
Admin documentation
See how to create your own instance.
See the more general admin documentation.
Tools documentation
Learn how to import/upload videos from CLI or admin your PeerTube instance with the tools documentation.
Technical documentation
See the architecture blueprint for a more detailed explanation of the architectural choices.
See our REST API documentation:
- OpenAPI 3.0.0 schema: /support/doc/api/openapi.yaml
- Spec explorer: docs.joinpeertube.org/api-rest-reference.html
See our ActivityPub documentation.
License
Copyright (C) 2015-2021 PeerTube Contributors (see CREDITS.md)
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/.