2019-04-10 15:43:16 -04:00
|
|
|
# Peertube setup with Ansible and Docker-Compose
|
|
|
|
|
2019-05-15 08:10:52 -04:00
|
|
|
This repo lets you easily setup a Peertube server based on docker-compose.
|
|
|
|
|
2019-05-16 14:05:38 -04:00
|
|
|
There is also a migration script to migrate from the
|
|
|
|
[default Peertube setup](https://github.com/Chocobozzz/PeerTube/blob/develop/support/doc/production.md)
|
|
|
|
to this setup. Use it at your own risk, and make sure to test and backup
|
|
|
|
before doing this migration.
|
|
|
|
|
2019-05-16 14:42:20 -04:00
|
|
|
This project is based on the
|
|
|
|
[Peertube docker-compose example](https://github.com/Chocobozzz/PeerTube/blob/develop/support/doc/docker.md).
|
|
|
|
|
2019-05-16 14:05:38 -04:00
|
|
|
You can contact me on the Fediverse about this project:
|
2019-07-15 14:54:44 -04:00
|
|
|
[@felix@radical.town](https://radical.town/@felix).
|
2019-05-16 14:05:38 -04:00
|
|
|
|
2019-05-15 08:10:52 -04:00
|
|
|
## Features
|
|
|
|
|
2019-07-15 14:54:44 -04:00
|
|
|
- easy, automatic setup
|
|
|
|
- integrated Let's Encrypt certificate handling
|
2019-05-15 08:10:52 -04:00
|
|
|
- file caching with nginx (to limit backend access and Peertube CPU usage)
|
|
|
|
- email sending works out of the box
|
|
|
|
|
2019-04-10 15:43:16 -04:00
|
|
|
## Setup
|
|
|
|
|
2019-05-15 08:10:52 -04:00
|
|
|
Clone the repo onto your local machine.
|
|
|
|
|
2019-04-19 08:37:26 -04:00
|
|
|
Copy `inventory.example` to `inventory`, and configure the hosts you want to work with.
|
2019-04-10 15:43:16 -04:00
|
|
|
|
2019-05-15 08:10:52 -04:00
|
|
|
Install Python and Ansible on your local machine:
|
2019-04-10 15:43:16 -04:00
|
|
|
|
2019-07-15 14:54:44 -04:00
|
|
|
apt install python2-pip
|
2019-04-10 15:43:16 -04:00
|
|
|
pip2 install ansible
|
|
|
|
|
|
|
|
Run the playbook:
|
|
|
|
|
2019-04-19 08:37:26 -04:00
|
|
|
ansible-playbook --become peertube.yml
|
2019-04-18 09:16:35 -04:00
|
|
|
|
2019-05-15 08:10:52 -04:00
|
|
|
The first time you run it, Ansible will output the root password.
|
|
|
|
|
|
|
|
Note: If you use this for an existing Peertube instance, make sure the file
|
|
|
|
`passwords/*your-server*/postgres` exists and contains the correct password. Otherwise
|
|
|
|
Ansible will change the password in Peertube, and it won't be able to connect to the database.
|