Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • adaures/castopod
  • mkljczk/castopod-host
  • spaetz/castopod-host
  • PatrykMis/castopod
  • jonas/castopod
  • ajeremias/castopod
  • misuzu/castopod
  • KrzysztofDomanczyk/castopod
  • Behel/castopod
  • nebulon/castopod
  • ewen/castopod
  • NeoluxConsulting/castopod
  • nateritter/castopod-og
  • prcutler/castopod
14 results
Show changes
---
title: Security concerns
---
Castopod is built on top of [CodeIgniter4](https://codeigniter.com/), a PHP
framework that encourages
[good security practices](https://codeigniter.com/user_guide/concepts/security.html).
To maximize your instance's safety and prevent any malicious attack, we
recommend you update all your Castopod files permissions after installation or
updates (to avoid any prior permission error):
- `writable/` folder must be **readable** and **writable**.
- `public/media/` folder must be **readable** and **writable**.
- any other file must be set to **readonly**.
For instance, if you are using Apache or NGINX with Ubuntu you may do the
following:
```bash
sudo chown -R root:root /path/to/castopod
sudo chown -R www-data:www-data /path/to/castopod/writable
sudo chown -R www-data:www-data /path/to/castopod/public/media
```
---
title: How to update Castopod?
---
import { Aside } from "@astrojs/starlight/components";
After installing Castopod, you may want to update your instance to the latest
version in order to enjoy the latest features ✨, bug fixes 🐛 and performance
improvements ⚡.
## Update instructions
0. ⚠️ Before any update, we highly recommend you backup your Castopod files and
database.
- cf.
[Should I make a backup before updating?](#should-i-make-a-backup-before-updating)
1. Go to the
[releases page](https://code.castopod.org/adaures/castopod/-/releases) and
see if your instance is up to date with the latest Castopod version
- cf.
[Where can I find my Castopod version?](#where-can-i-find-my-castopod-version)
2. Download the latest release package named `Castopod Package`, you may choose
between the `zip` or `tar.gz` archives
- ⚠️ Make sure you download the Castopod Package and **NOT** the Source Code
- Note that you can also download the latest package from
[castopod.org](https://castopod.org/)
3. On your server:
- Remove all files except `.env` and `public/media`
- Copy the new files from the downloaded package into your server
<Aside>
You may need to reset files permissions as during the install process.
Check [Security Concerns](./security.md).
</Aside>
4. Update your database schema from your `Castopod Admin` > `About` page or by
running:
```bash
php spark castopod:database-update
```
5. Clear your cache from your `Castopod Admin` > `Settings` > `general` >
`Housekeeping`
6. ✨ Enjoy your fresh instance, you're all done!
<Aside>
Releases may come with additional update instructions (see
[releases page](https://code.castopod.org/adaures/castopod/-/releases)).
- cf.
[I haven't updated my instance in a long time… What should I do?](#i-havent-updated-my-instance-in-a-long-time-what-should-i-do)
</Aside>
## Fully Automated updates
> Coming soon... 👀
## Frequently asked questions (FAQ)
### Where can I find my Castopod version?
Go to your Castopod admin panel, the version is displayed on the bottom left
corner.
Alternatively, you can find the version in the `app > Config > Constants.php`
file.
### I haven't updated my instance in a long time… What should I do?
No problem! Just get the latest release as described above. Only, when going
through the release instructions (4), perform them sequentially, from the oldest
to the newest.
> You may want to backup your instance depending on how long you haven't updated
> Castopod.
For example, if you're on `v1.0.0-alpha.42` and would like to upgrade to
`v1.0.0-beta.1`:
0. (highly recommended) Make a backup of your files and database.
1. Download the latest release, overwrite your files whilst keeping `.env` and
`public/media`.
2. Go through each release update instructions sequentially (from oldest to
newest) starting with `v1.0.0-alpha.43`, `v1.0.0-alpha.44`,
`v1.0.0-alpha.45`, …, `v1.0.0-beta.1`.
3. ✨ Enjoy your fresh instance, you're all done!
### Should I make a backup before updating?
We advise you do, so you don't lose everything if anything goes wrong!
More generally, we advise you make regular backups of your Castopod files and
database to prevent you from losing it all…
---
title: Welcome 👋
---
import { LinkCard } from "@astrojs/starlight/components";
Castopod is a free & open-source hosting platform made for podcasters who want
engage and interact with their audience.
Castopod is easy to install and was built on top of
[CodeIgniter4](https://codeigniter.com/), a powerful PHP framework with a very
small footprint.
<LinkCard title="Install" href="./getting-started/install" />
## Features
- 🌱 Free & open-source (AGPL v3 License)
- 🔐 Focused on data sovereignty: your content, audience, and analytics belong
to you, and you only
- 🪄 Podcasting 2.0 features: GUID, locked, transcripts, funding, chapters,
location, persons, soundbites, …
- 💬 Built-in social network:
- 🚀 Castopod is part of the Fediverse, a decentralized social network
- ❤️ Create posts, share, favourite, and comment on episodes
- 📈 Built-in analytics:
- ⚖️ GDPR / CCPA / LGPD compliant
- 🪙 Standard IABv2 audience measurement
- 🏡 On-premises analytics, no third party involved
- 📢 Built-in marketing tools:
- ✅ SEO ready (open-graph meta-tags, JSON-LD, …)
- 📱 PWA: install as a standalone app
- 🎨 Customizable theme colors
- 🎬 Generate ready-to-share Video clips from episodes
- 🔉 Generate soundbites
- ▶️ Embeddable player, embed your episodes on any website
- 💸 Monetization:
- 🔗 Funding links
- 📲 listen-to-click ads
- 🤝 value4value / WebMonetization
- 💎 Premium podcasts
- 📡 Publish your episodes everywhere with RSS:
- 📱 On all indexes and apps: Podcast Index, Apple Podcasts, Spotify, Google
Podcasts, Deezer, Podcast Addict, Podfriend, …
- ⚡ Broadcast your episodes instantly with WebSub
- 📥 Podcast import: move your existing podcast into Castopod
- 📤 Move your podcast out of Castopod
- 🔀 Multi-tenant: host as many podcasts as you want
- 👥 Multi-user: add contributors and set roles
- 🌎 i18n support: translated in English, French, Polish, German, Brazilian
Portuguese, Spanish, simplified Chinese… and
[many more](https://translate.castopod.org)!
## Motivation
The podcasting ecosystem is decentralized by nature: you can create your podcast
as an RSS file, publish it on the web and have it shared everywhere online.
It is in fact one of the only media to have stayed this way for a long time.
As usages are evolving, more and more people are getting into podcasts: whether
it is creators finding new ways to share their ideas, or listeners in the search
for better content.
With podcasting becoming more widely used, some companies are trying to shift it
towards a more controlled and centralized medium.
Castopod was created in an effort to provide an open and sustainable alternative
to hosting your podcasts, promoting decentralization to ensure that podcasters
creativity can express itself.
This project is pushed by the open-source community, and specifically by the
[Fediverse](https://fediverse.party/en/fediverse/) and
[Podcasting 2.0](https://podcastindex.org/) movements.
## Comparison with other solutions
We believe that a solution is not necessarily right for everyone, it highly
depends on your needs. So, here are comparisons with other tools to help you to
gauge whether Castopod is the right fit for you.
### Castopod vs Wordpress
Castopod is often referred to as "the Wordpress for podcasts" because of the
similarities between the two. In some ways this is true. And actually, Castopod
was greatly inspired by the Wordpress ecosystem, seeing the ease of adoption
from the community and the number of websites running it.
Just like Wordpress, Castopod is free & open source, built using PHP with a
MySQL database and is packaged in a way that you can easily install on most web
servers.
Wordpress is a great way to create your website and extend it with plugins to
get what you want. It is a full fledged CMS that helps you get any type of
website online.
On the other hand, Castopod is meant to address the podcasters needs
specifically, focusing on podcasting, and nothing else. You don't need any
plugin to get you started on your podcasting journey.
This allows optimizing the processes specific to podcasting: ranging from the
creation of your podcasts and the publication of new episodes all the way to
broadcasting, marketing and analytics.
Finally, depending on your needs, Wordpress and Castopod can even live side by
side as they share the same requirements!
### Castopod vs Funkwhale
Funkwhale is a self-hosted, modern free and open-source music server. Just as
Castopod, Funkwhale is on the fediverse, a decentralized social network allowing
interoperability between the two.
Funkwhale was initially built around music. And later on, as the project
evolved, the ability to host podcasts was introduced.
Unlike Funkwhale, Castopod has been designed and built around podcasting
exclusively. This allows easier implementation for features related to the
podcasting ecosystem, such as the podcasting 2.0 features (transcripts,
chapters, locations, persons, …).
So, you should probably use Funkwhale if you want to host your music, and use
Castopod if you want to host your podcasts.
### Castopod vs other podcast hosts
There are many solutions for you to host your podcasts, some of which are really
great and [a lot of them](https://podcastindex.org/apps) are jumping into the
Podcasting 2.0 wagon just like Castopod!
Each of these solutions differ from one another, you may compare with the
[list of features](#features).
That being said, there are two main differences with other podcasting solutions:
- Castopod can be self-hosted and is the only solution that allows you to keep
full control over what you produce. Also, as it is open-source, you can even
customize it as you wish.
- Castopod is the only solution that currently integrates both a decentralized
social network with ActivityPub as well as many of the podcasting 2.0
features, hoping to bridge the gap between the two.
## Contributing
Love Castopod and would like to help? Take a look at the following documentation
to get you started.
### Code of conduct
Castopod has adopted a Code of Conduct that we expect project participants to
adhere to. Please read the
[CODE_OF_CONDUCT manual](https://code.castopod.org/adaures/castopod/-/blob/beta/CODE_OF_CONDUCT.md)
so that you can understand what actions will and will not be tolerated.
### Contributing guide
Read our
[contributing guide](https://code.castopod.org/adaures/castopod/-/blob/develop/CONTRIBUTING.md)
to learn about our development process, how to propose bugfixes and
improvements, and how to build and test your changes to Castopod.
## Contact
You may reach us for help or ask any question you have on:
- [Discord](https://castopod.org/discord) (for direct interaction with
developers and the community)
- [Issue tracker](https://code.castopod.org/adaures/castopod/-/issues) (for
feature requests & bug reports)
Alternatively, you can follow us on social media platforms to get news about
Castopod:
- [podlibre.social](https://podlibre.social/@Castopod) (Mastodon instance)
- [Twitter](https://twitter.com/castopod)
- [LinkedIn](https://linkedin.com/company/castopod)
- [Facebook](https://www.facebook.com/castopod)
## Sponsors
The ongoing development of Castopod is made possible with the support of its
backers. If you'd like to help, please consider
[sponsoring Castopod's development](https://opencollective.com/castopod/contribute).
[![Ad Aures Logo](../../../assets/images/sponsors/adaures.svg)](https://adaures.com/)
[![NLnet Logo](../../../assets/images/sponsors/nlnet.svg)](https://nlnet.nl/)
## License
[GNU Affero General Public License v3.0](https://choosealicense.com/licenses/agpl-3.0/)
Copyright © 2020-present, [Ad Aures](https://adaures.com/).
---
title: Authentification et Autorisation
---
Castopod gère l'authentification et l'autorisation à l'aide de
`codeigniter/shield` associés à des règles personnalisées. Les rôles et les
autorisations sont définis sur deux niveaux :
1. [à l'échelle de l'instance](#1-instance-wide-roles-and-permissions)
2. [par podcast](#2-per-podcast-roles-and-permissions)
## 1. Rôles et autorisations à l'échelle de l'instance
### Instance roles
{/* AUTH-INSTANCE-ROLES-LIST:START - Do not remove or modify this section */}
| role | description | permissions |
| -------------------------- | ----------------------------------- | ------------------------------------------------------------------------------------------------------ |
| Super administrat·rice·eur | A un contrôle complet sur Castopod. | admin.\*, plugins.\*, podcasts.\*, users.manage, persons.manage, pages.manage, fediverse.manage-blocks |
| Gestionnaire | Gère le contenu de Castopod. | podcasts.create, podcasts.import, persons.manage, pages.manage |
| Podcast·rice·eur | Utilisateurs généraux de Castopod. | admin.access |
{/* AUTH-INSTANCE-ROLES-LIST:END */}
### Autorisations dans l'instance
{/* AUTH-INSTANCE-PERMISSIONS-LIST:START - Do not remove or modify this section */}
| permission | description |
| ----------------------- | -------------------------------------------------------------------- |
| admin.access | Peut accéder à la zone d'administration Castopod. |
| admin.settings | Peut accéder aux paramètres de Castopod. |
| plugins.manage | Auth.instance_permissions.plugins.manage |
| users.manage | Peut gérer les utilisateurs de Castopod. |
| persons.manage | Permet de gérer les personnes. |
| pages.manage | Permet de gérer les pages. |
| podcasts.view | Peut voir tous les podcasts. |
| podcasts.create | Peut créer de nouveaux podcasts. |
| podcasts.import | Peut importer des podcasts. |
| fediverse.manage-blocks | Peut empêcher des act·rice·eur·s/domaines d'interagir avec Castopod. |
{/* AUTH-INSTANCE-PERMISSIONS-LIST:END */}
## 2. Rôles et autorisations par podcast
### Rôles par podcast
{/* AUTH-PODCAST-ROLES-LIST:START - Do not remove or modify this section */}
| role | description | permissions |
| ---------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Administrateur | A un contrôle total sur le podcast #\{id\}. | \* |
| Éditeur | Gère le contenu et les publications du podcast #\{id\}. | view, edit, manage-import, manage-persons, manage-platforms, manage-publications, manage-notifications, interact-as, episodes.view, episodes.create, episodes.edit, episodes.delete, episodes.manage-persons, episodes.manage-clips, episodes.manage-publications, episodes.manage-comments |
| Auteur / Autrice | Gère le contenu du podcast #\{id\} , mais ne peut pas le publier. | view, manage-persons, episodes.view, episodes.create, episodes.edit, episodes.manage-persons, episodes.manage-clips |
| Invité | Contributeur général du podcast #\{id\}. | view, episodes.view |
{/* AUTH-PODCAST-ROLES-LIST:END */}
### Permissions par podcast
{/* AUTH-PODCAST-PERMISSIONS-LIST:START - Do not remove or modify this section */}
| permission | description |
| ---------------------------- | ---------------------------------------------------------------------------------------------------- |
| view | Peut voir le tableau de bord et les analyses du podcast #\{id\}. |
| edit | Peut éditer le podcast #\{id\}. |
| delete | Peut supprimer le podcast #\{id\}. |
| manage-import | Peut synchroniser le podcast importé #\{id\}. |
| manage-persons | Permet de gérer les abonnements au podcast #\{id\}. |
| manage-subscriptions | Permet de gérer les abonnements au podcast #\{id\}. |
| manage-contributors | Permet de gérer les contributeurs du podcast #\{id\}. |
| manage-platforms | Peut configurer/supprimer les liens de la plateforme du podcast #\{id\}. |
| manage-publications | Peut publier le podcast #\{id\}. |
| manage-notifications | Peut afficher et marquer les notifications comme lues pour le podcast #\{id\}. |
| interact-as | Peut interagir en tant que podcast #\{id\} pour mettre en favori, partager ou répondre aux messages. |
| episodes.view | Peut voir le tableau de bord et les statistiques du podcast #\{id\}. |
| episodes.create | Peut créer des épisodes pour le podcast #\{id\}. |
| episodes.edit | Peut modifier les épisodes du podcast #\{id\}. |
| episodes.delete | Peut supprimer les épisodes du podcast #\{id\}. |
| episodes.manage-persons | Peut gérer les intervenants des épisodes du podcast #\{id\}. |
| episodes.manage-clips | Permet de gérer les clips vidéo ou les parties sonores du podcast #\{id\}. |
| episodes.manage-publications | Peut publier/dépublier des épisodes et des messages de podcast #\{id\}. |
| episodes.manage-comments | Peut créer/supprimer les commentaires de l'épisode du podcast #\{id\}. |
{/* AUTH-PODCAST-PERMISSIONS-LIST:END */}
---
title: Images officielles de Docker
---
Castopod envoie 3 images Docker au Hub Docker pendant son processus de
construction automatisée :
- [**`castopod/castopod`**](https://hub.docker.com/r/castopod/castopod): une
image castopod tout-en-un sous nginx unit
- [**`castopod/app`**](https://hub.docker.com/r/castopod/app): le paquet
d'applications avec toutes les dépendances de Castopod
- [**`castopod/web-server`**](https://hub.docker.com/r/castopod/web-server): une
configuration Nginx pour Castopod
De plus, Castopod nécessite une base de données compatible avec MySQL. Une base
de données Redis peut être ajoutée en tant que gestionnaire de cache.
## Tags supportés
- `développer` [unstable], la dernière version de la branche de développement
- `beta` [stable], dernière version bêta
- `beta` [stable], dernière version bêta
- `1.x.x` [stable], version spécifique (depuis `1.0.0`)
## Exemple d'utilisation
1. Installez [docker](https://docs.docker.com/get-docker/) et
[docker-compose](https://docs.docker.com/compose/install/)
2. Créez un fichier `docker-compose.yml` avec les éléments suivants :
```yml
version: "3.7"
services:
app:
image: castopod/castopod:latest
container_name: "castopod-app"
volumes:
- castopod-media:/var/www/castopod/public/media
environment:
MYSQL_DATABASE: castopod
MYSQL_USER: castopod
MYSQL_PASSWORD: changeme
CP_BASEURL: "https://castopod.example.com"
CP_ANALYTICS_SALT: changeme
CP_CACHE_HANDLER: redis
CP_REDIS_HOST: redis
CP_REDIS_PASSWORD: changeme
networks:
- castopod-app
- castopod-db
ports:
- 8000:8000
restart: unless-stopped
mariadb:
image: mariadb:10.5
container_name: "castopod-mariadb"
networks:
- castopod-db
volumes:
- castopod-db:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: changeme
MYSQL_DATABASE: castopod
MYSQL_USER: castopod
MYSQL_PASSWORD: changeme
restart: unless-stopped
redis:
image: redis:7.0-alpine
container_name: "castopod-redis"
command: --requirepass changeme
volumes:
- castopod-cache:/data
networks:
- castopod-app
volumes:
castopod-media:
castopod-db:
castopod-cache:
networks:
castopod-app:
castopod-db:
```
Vous devez adapter certaines variables à vos besoins (p. ex. `CP_BASEURL`,
`MYSQL_ROOT_PASSWORD`, `MYSQL_PASSWORD` et `CP_ANALYTICS_SALT`).
3. Setup a reverse proxy for TLS (SSL/HTTPS)
TLS is mandatory for ActivityPub to work. This job can easily be handled by a
reverse proxy, for example with [Caddy](https://caddyserver.com/):
```
#castopod
castopod.example.com {
reverse_proxy localhost:8000
}
```
4. Exécutez `docker-compose up -d`, attendez qu'il s'initialise sur
`https://castopod.example.com/cp-install` pour terminer la configuration de
Castopod !
5. Vous êtes prêt, commencez à podcaster! 🎙️🚀
## Environment Variables
- **castopod/castopod** and **castopod/app**
| Variable name | Type (`default`) | Par défaut |
| ------------------------------------- | ----------------------- | ---------------- |
| **`CP_BASEURL`** | string | `undefined` |
| **`CP_MEDIA_BASEURL`** | ?string | `CP_BASEURL` |
| **`CP_ADMIN_GATEWAY`** | ?string | `"cp-admin"` |
| **`CP_AUTH_GATEWAY`** | ?string | `"cp-auth"` |
| **`CP_ANALYTICS_SALT`** | string | `undefined` |
| **`CP_DATABASE_HOSTNAME`** | ?string | `"mariadb"` |
| **`CP_DATABASE_NAME`** | ?string | `MYSQL_DATABASE` |
| **`CP_DATABASE_USERNAME`** | ?string | `MYSQL_USER` |
| **`CP_DATABASE_PASSWORD`** | ?string | `MYSQL_PASSWORD` |
| **`CP_DATABASE_PREFIX`** | ?string | `"cp_"` |
| **`CP_CACHE_HANDLER`** | [`"file"` or `"redis"`] | `"file"` |
| **`CP_REDIS_HOST`** | ?string | `"localhost"` |
| **`CP_REDIS_PASSWORD`** | ?string | `null` |
| **`CP_REDIS_PORT`** | ?number | `6379` |
| **`CP_REDIS_DATABASE`** | ?number | `0` |
| **`CP_EMAIL_SMTP_HOST`** | ?string | `undefined` |
| **`CP_EMAIL_FROM`** | ?string | `undefined` |
| **`CP_EMAIL_SMTP_USERNAME`** | ?string | `"localhost"` |
| **`CP_EMAIL_SMTP_PASSWORD`** | ?string | `null` |
| **`CP_EMAIL_SMTP_PORT`** | ?number | `25` |
| **`CP_EMAIL_SMTP_CRYPTO`** | [`"tls"` or `"ssl"`] | `"tls"` |
| **`CP_ENABLE_2FA`** | ?boolean | `undefined` |
| **`CP_MEDIA_FILE_MANAGER`** | ?string | `undefined` |
| **`CP_MEDIA_S3_ENDPOINT`** | ?string | `undefined` |
| **`CP_MEDIA_S3_KEY`** | ?string | `undefined` |
| **`CP_MEDIA_S3_SECRET`** | ?string | `undefined` |
| **`CP_MEDIA_S3_REGION`** | ?string | `undefined` |
| **`CP_MEDIA_S3_BUCKET`** | ?string | `undefined` |
| **`CP_MEDIA_S3_PROTOCOL`** | ?number | `undefined` |
| **`CP_MEDIA_S3_PATH_STYLE_ENDPOINT`** | ?boolean | `undefined` |
| **`CP_MEDIA_S3_KEY_PREFIX`** | ?string | `undefined` |
| **`CP_DISABLE_HTTPS`** | ?[`0` or `1`] | `undefined` |
| **`CP_MAX_BODY_SIZE`** | ?number (with suffix) | `512M` |
| **`CP_PHP_MEMORY_LIMIT`** | ?number (with suffix) | `512M` |
| **`CP_TIMEOUT`** | ?number | `900` |
- **castopod/web-server**
| Variable name | Type | Par défaut |
| ---------------------- | --------------------- | ---------- |
| **`CP_APP_HOSTNAME`** | ?string | `"app"` |
| **`CP_MAX_BODY_SIZE`** | ?number (with suffix) | `512M` |
| **`CP_TIMEOUT`** | ?number | `900` |
---
title: Comment installer Castopod ?
---
import { Aside } from "@astrojs/starlight/components";
Castopod a été pensé pour être facile à installer. Que vous utilisiez un
hébergement dédié ou mutualisé, vous pouvez l'installer sur la plupart des
serveurs web compatibles avec PHP-MySQL.
## Prérequis
- PHP v8.4 ou supérieure
- MySQL version 8.4 ou supérieure ou MariaDB version 11.4 ou supérieure
- Prise en charge HTTPS
- Une horloge [synchronisée ntp](https://wiki.debian.org/NTP) pour valider les
requêtes fédérés entrantes
### PHP v8.4 ou supérieure
PHP version 8.4 ou supérieure est requise, avec les extensions suivantes
installées :
- [intl](https://www.php.net/manual/fr/intl.requirements.php)
- [libcurl](https://www.php.net/manual/fr/curl.requirements.php)
- [mbstring](https://www.php.net/manual/fr/mbstring.installation.php)
- [gd](https://www.php.net/manual/en/image.installation.php) avec **JPEG**,
**PNG** et bibliothèques **WEBP**.
- [exif](https://www.php.net/manual/fr/exif.installation.php)
De plus, assurez-vous que les extensions suivantes sont activées dans votre PHP
:
- json (activé par défaut - ne le désactivez pas)
- xml (activé par défaut - ne pas le désactiver)
- [mysqlnd](https://www.php.net/manual/fr/mysqlnd.install.php)
### Base de données compatible MySQL
> Nous vous recommandons d'utiliser [MariaDB](https://mariadb.org).
Vous aurez besoin du nom d'hôte du serveur, du nom de la base de données, du nom
d'utilisateur et du mot de passe pour terminer le processus d'installation. Si
vous ne disposez pas de ces informations, veuillez contacter votre
administrateur.
#### Droits d'accès
L'utilisateur doit avoir au moins ces droits d'accès sur la base de données pour
que Castopod fonctionne : `CREATE`, `ALTER`, `DELETE`, `EXECUTE`,
`INDEX`,`INSERT`, `SELECT`, `UPDATE`,`REFERENCES`, `CREATE VIEW`.
### (Facultatif) FFmpeg v4.1.8 ou supérieur pour les clips vidéo
[FFmpeg](https://www.ffmpeg.org/) version 4.1.8 ou supérieure est requis si vous
souhaitez générer des Clips Vidéo. Les extensions suivantes doivent être
installées :
- bibliothèque **FreeType 2** pour
[gd](https://www.php.net/manual/en/image.installation.php).
### (Facultatif) Autres recommandations
- Redis pour de meilleures performances de cache.
- CDN pour la mise en cache de fichiers statiques et de meilleures performances.
- passerelle e-mail pour les mots de passe perdus.
## Instructions d'installation
### Pré-requis
0. Obtenez un serveur Web avec [les pré-requis](#requirements) installés
1. Créer une base de données MySQL pour Castopod avec un utilisateur ayant les
droits d'accès et les droits de modification (pour plus d'informations, cf.
[base de données compatible MySQL](#mysql-compatible-database)).
2. Activez HTTPS sur votre domaine avec un _certificat SSL_.
3. Téléchargez et dézippez le dernier [paquet Castopod](https://castopod.org/)
sur le serveur web si vous ne l'avez pas déjà fait.
- ⚠️ Faites pointer la racine du document du serveur web vers le sous-dossier
`public/` du dossier `castopod`.
4. Add **cron tasks** on your web server for various background processes
(replace the paths accordingly):
```bash
* * * * * /path/to/php /path/to/castopod/spark tasks:run >> /dev/null 2>&1
```
**Note** - If you do not add this cron task, the following Castopod features
will not work:
- Importing a podcast from an existing RSS feed
- Broadcasting social activities to your followers in the fediverse
- Broadcasting episodes to open hubs using
[WebSub](https://en.wikipedia.org/wiki/WebSub)
- Generating video clips -
[requires FFmpeg](#optional-ffmpeg-v418-or-higher-for-video-clips)
### (Méthode recommandée) Assistant d'installation
1. Exécutez le script d'installation de Castopod en vous rendant sur la page
d'assistant d'installation (`https://votre_domain_name.com/cp-install`) dans
votre navigateur Web favori.
2. Suivez les instructions affichée.
3. Commencer à baladodiffuser !
<Aside>
Le script d'installation crée un fichier `.env` à la racine du paquet. Si vous
ne pouvez pas passer par l'assistant d'installation, vous pouvez créer et éditer
le fichier `.env` manuellement en vous appuyant sur le fichier `.env.example`.
</Aside>
### Utilisation du CLI
1. Créez un fichier `.env` à la racine du paquet basé sur le fichier
`.env.example`.
2. Initialisez la base de données en exécutant :
```sh
php spark install:init-database
```
3. Créer l'utilisateur super-admin en utilisant :
```sh
php spark install:create-superadmin
```
4. Rendez-vous sur votre passerelle d'administration pour commencer le
podcasting!
### Configuration SMTP∕Email
Email configuration is required for some features to work properly (eg.
retrieving your forgotten password, sending instructions to premium subscribers,
…)
You may add your email configuration in your instance's `.env` like so:
```ini
# […]
email.fromEmail="your_email_address"
email.SMTPHost="your_smtp_host"
email.SMTPUser="your_smtp_user"
email.SMTPPass="your_smtp_password"
```
#### Email config options
| Variable name | Type | Default |
| ---------------- | -------------------- | ------------ |
| **`fromEmail`** | string | `undefined` |
| **`fromName`** | string | `"Castopod"` |
| **`SMTPHost`** | string | `undefined` |
| **`SMTPUser`** | string | `undefined` |
| **`SMTPPass`** | string | `undefined` |
| **`SMTPPort`** | number | `25` |
| **`SMTPCrypto`** | [`"tls"` or `"ssl"`] | `"tls"` |
### Media storage
By default, files are saved to the `public/media` folder using the file system.
If you need to relocate the `media` folder to a different location, you can
specify it in your `.env` file as shown below:
```ini
# […]
media.root="media"
media.storage="/mnt/storage"
```
In this example, the files will be saved to the /mnt/storage/media folder. Make
sure to also update your web server configuration to reflect this change.
### S3
If you prefer storing your media files on an S3 compatible storage, you may
specify it in your `.env`:
```ini
# […]
media.fileManager="s3"
media.s3.endpoint="your_s3_host"
media.s3.key="your_s3_key"
media.s3.secret="your_s3_secret"
media.s3.region="your_s3_region"
```
#### Options de configuration S3
| Variable name | Type | Default |
| ----------------------- | ------- | ----------- |
| **`endpoint`** | string | `undefined` |
| **`key`** | string | `undefined` |
| **`secret`** | string | `undefined` |
| **`region`** | string | `undefined` |
| **`bucket`** | string | `castopod` |
| **`protocol`** | number | `undefined` |
| **`pathStyleEndpoint`** | boolean | `false` |
| **`keyPrefix`** | string | `undefined` |
## Paquets fournis par la communauté
If you don't want to bother with installing Castopod manually, you may use one
of the packages created and maintained by the open-source community.
### Installation avec Yunohost
[YunoHost](https://yunohost.org/) est une distribution basée sur Debian
GNU/Linux composée de logiciels libres et open source. Cela permet de vous
simplifier l'auto-hébergement.
<div class="flex flex-wrap items-center gap-4">
<a
href="https://install-app.yunohost.org/?app=castopod"
target="_blank"
rel="noopener noreferrer"
>
<img
src="https://install-app.yunohost.org/install-with-yunohost.svg"
alt="Installer avec YunoHost"
class="align-middle"
/>
</a>
<a
href="https://github.com/YunoHost-Apps/castopod_ynh"
target="_blank"
rel="noopener noreferrer"
class="inline-flex items-center px-4 py-[.3rem] mx-auto font-semibold text-center text-black rounded-md gap-x-1 border-2 border-solid border-[#333] hover:no-underline hover:bg-gray-100"
>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
width="1em"
height="1em"
class="text-xl"
>
<path fill="none" d="M0 0h24v24H0z" />
<path d="M12 2A10 10 0 0 0 2 12a10 10 0 0 0 6.84 9.49c.5.09.69-.21.69-.48l-.02-1.86c-2.51.46-3.16-.61-3.36-1.18-.11-.28-.6-1.17-1.02-1.4-.35-.2-.85-.66-.02-.67.79-.01 1.35.72 1.54 1.02.9 1.52 2.34 1.1 2.91.83a2.1 2.1 0 0 1 .64-1.34c-2.22-.25-4.55-1.11-4.55-4.94A3.9 3.9 0 0 1 6.68 8.8a3.6 3.6 0 0 1 .1-2.65s.83-.27 2.75 1.02a9.28 9.28 0 0 1 2.5-.34c.85 0 1.7.12 2.5.34 1.9-1.3 2.75-1.02 2.75-1.02.54 1.37.2 2.4.1 2.65.63.7 1.02 1.58 1.02 2.68 0 3.84-2.34 4.7-4.56 4.94.36.31.67.91.67 1.85l-.01 2.75c0 .26.19.58.69.48A10.02 10.02 0 0 0 22 12 10 10 0 0 0 12 2z" />
</svg>
Dépôt Github
</a>
</div>
---
title: Questions de sécurité
---
Castopod est développé sur [CodeIgniter4](https://codeigniter.com/), un
framework PHP qui encourage
[de bonnes pratiques de sécurité](https://codeigniter.com/user_guide/concepts/security.html).
Pour garantir au mieux la sécurité de votre instance et éviter les attaques
malveillantes, nous vous recommandons de mettre à jour les permissions des
fichiers de Castopod après l'installation et chaque mise à jour (et éviter toute
erreur de droit d'accès aux fichiers) :
- Le dossier `writable/` doit être accessible en **lecture** et en **écriture**.
- Le dossier `public/media/` doit être accessible en **lecture** et en
**écriture**.
- tout autre fichier doit être accessible en **lecture seule**.
Par exemple, si vous utilisez Apache ou NGINX avec Ubuntu, vous pouvez exécuter
les commandes suivantes :
```bash
sudo chown -R root:root /path/to/castopod
sudo chown -R www-data:www-data /path/to/castopod/writable
sudo chown -R www-data:www-data /path/to/castopod/public/media
```
---
title: Comment installer Castopod ?
---
import { Aside } from "@astrojs/starlight/components";
Après avoir installé Castopod, vous pouvez mettre à jour votre instance vers la
dernière version afin de profiter des dernières fonctionnalités ✨, des
corrections de bugs 🐛 et des améliorations de performance ⚡.
## Instructions de mise à jour
0. ⚠️ Avant toute mise à jour, nous vous recommandons fortement de sauvegarder
vos fichiers Castopod et la base de données .
- cf.
[Should I make a backup before updating?](#should-i-make-a-backup-before-updating)
1. Allez à la page
[des versions](https://code.castopod.org/adaures/castopod/-/releases) et
vérifiez si votre instance est à jour avec la dernière version de Castopod
- cf.
[Where can I find my Castopod version?](#where-can-i-find-my-castopod-version)
2. Téléchargez la dernière version du paquet nommé `Castopod Package`. Vous
pouvez choisir entre les archives au format `zip` ou `tar.gz`
- ⚠️ Assurez-vous de bien télécharger le paquet Castopod et **NON** le code
source
- Notez que vous pouvez également télécharger le dernier paquet depuis
[castopod.org](https://castopod.org/)
3. Sur votre serveur :
- Supprimer tous les fichiers sauf `.env` et `public/media`
- Copiez les nouveaux fichiers du paquet téléchargé sur votre serveur
<Aside>
Vous devrez peut-être re-définir les autorisations de fichiers comme
effectué durant le processus d'installation. Vérifiez les
[questions de sécurité](./security.md).
</Aside>
4. Mettez à jour votre schéma de base de données depuis
`Administrateur Castopod` > `À propos` ou en exécutant :
```bash
php spark castopod:database-update
```
5. Videz votre cache de votre `Administrateur Castopod` > `Paramètres` >
`Général` > `Foyer`
6. ✨Profitez de votre nouvelle instance, vous avez terminé !
<Aside>
Les versions peuvent être accompagnées d'instructions de mise à jour
supplémentaires (cf. la
[page des notes de versions](https://code.castopod.org/adaures/castopod/-/releases)).
- [Je n'ai pas mis à jour mon instance depuis longtemps… Que devrais-je faire ?](#i-havent-updated-my-instance-in-a-long-time-what-should-i-do)
</Aside>
## Mises à jour entièrement automatisées
> Prochainement... 👀
## Foire Aux Questions (FAQ)
### Où puis-je trouver ma version de Castopod ?
Allez dans votre panneau d'administration de Castopod, la version s'affiche en
bas à gauche.
Vous pouvez également trouver la version dans l'application
`> Configuration > Constantes.php` dossier.
### cf. Je n'ai pas mis à jour mon instance depuis longtemps… Que devrais-je faire
?
Pas de problème ! Il suffit d'obtenir la dernière version comme décrit
ci-dessus. Lorsque vous exécutez les instructions de mise à jour (4), lancez-les
séquentiellement, de la plus ancienne à la plus récente.
> Vous devriez sauvegarder votre instance selon la date de votre dernière mise à
> jour de Castopod.
Par exemple, si vous êtes en `v1.0.0-alpha.42` et souhaitez mettre à jour vers
la `v1.0.0-beta.1` :
0. (fortement recommandé) Faites une sauvegarde de vos fichiers et de votre base
de données.
1. Téléchargez la dernière version, écrasez vos fichiers tout en conservant
`.env` et `public/media`.
2. Go through each release update instructions sequentially (from oldest to
newest) starting with `v1.0.0-alpha.43`, `v1.0.0-alpha.44`,
`v1.0.0-alpha.45`, …, `v1.0.0-beta.1`.
3. ✨ Votre nouvelle instance est prête !
### Dois-je faire une sauvegarde avant de mettre à jour ?
Nous vous conseillons de le faire, afin de ne pas tout perdre si quelque chose
se passait mal !
Plus généralement, nous vous conseillons de faire des sauvegardes régulières de
vos fichiers Castopod et de votre base de données afin d'éviter de tout perdre…