- Rust 96.5%
- CSS 3.5%
| assets | swap the sample file for an mp3 | |
| css | fix card styles being a link | |
| migrations | swap the sample file for an mp3 | |
| src | Merge pull request 'Swap to using MP3s' ( #81 ) from feature/swap-to-mp3 into main | |
| static | Adding well known funding pointer file back to limeleaf | |
| .gitignore | fix audio source seed data | |
| Cargo.lock | secure the cookies used | |
| Cargo.toml | secure the cookies used | |
| CODE_OF_CONDUCT.md | adapt COC from Veilid | |
| config.sample.toml | update rss feed with correct subdomainless base url | |
| LICENSE | Rename LICENSE | |
| README.md | instructions how to seed the database with sample data | |
| rust-toolchain.toml | devex stuff | |
limecast
A Distributed Podcasting Platform
Contributing
Since we are building this in public, we value any contributions from folks who find this project valuable. There are many ways to contribute to:
- Patches and pull requests
- Documentation
- Testing and bug finding/squashing
- Financially
Before you get started, please review our Code of Conduct. Our goal is to improve the world, and we cannot do that unless we treat each other with respect.
System Dependancies
Everything should be packaged pretty well with Rust and it is
recommended that you install Rust with rustup to manage different
version if needed. rustup is like other toolchain version managers and
it will honor whatever version of Rust is defined in
./rust-toolchain.toml which is currently set to the stable channel
of version releases.
Package Dependancies
axum & Friends
axum is one of the many projects in the Tokio ecosystem and is
one of the most popular web toolkits for Rust.
maud
maud allows us to write our HTML template as Rust macros to get
compile-time safety. No code generation, no external template files,
just plain Rust with a minimal DSL.
sqlx
sqlx is not an ORM. It is merely a SQL toolkit that has support for
serializing/deserialzing SQL results right into Rust structs, async
connection pool management, migrations, and macros for convenience.
Installing Rust
% curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Note: Copied from https://www.rust-lang.org/tools/install
Installing SQLite (optional)
Rust may complain if there are missing libraries for SQLite so if you need to install SQLite then you can use whatever system package manager is convenient to install it.
- Mac:
brew install sqlite - Ubuntu:
sudo apt install sqlite3
Configuration
Copy the config.sample.toml to config.toml in the same directory
and change any values you need, but the defaults are fine for getting
started.
You can also set the same config variables as env vars with a
LIMECAST_* prefix (ex. LIMECAST_BASE_URL=mydomain.com).
Running
The database create and migrations will automatically get checked and
ran if they need to be so you only need to run everything with a single
command. cargo is Rust's package manager and build system for
projects.
% cargo run
Load up the browser at http://<config.base_url>
Seeding Database
By default there will be no data in the database when migrations are run. If you would like to seed the database with an account and some podcasts then you can run the following:
% cat ./migrations/seed.sql | sqlite3 limecast.db
Viewing Podcast Websites
Each podcast will have a public website viewable with their
/@<podcast-slug> route like most ActivityPub instances use.
Example: http://<config.base_url>/@<podcast-slug>
Testing
Once we have tests just use cargo to run then.
% cargo test
Code Tools
Everything will be installed when using rustup since they are defined
in the ./rust-toolchain.toml. The "blessed" tools are rust-analyzer,
rustfumt, and clippy.