mirror of
https://github.com/versia-pub/server.git
synced 2026-04-27 20:59:15 +02:00
Add new scripts and update README.md
This commit is contained in:
parent
8fa16d4e09
commit
b241e33cf9
5 changed files with 208 additions and 36 deletions
54
README.md
54
README.md
|
|
@ -1,4 +1,6 @@
|
|||
# Lysand
|
||||
<p align="center">
|
||||
<a href="https://lysand.org"><img src="https://cdn-web.cpluspatch.com/lysand.webp" alt="Lysand Logo" height=130></a>
|
||||
</p>
|
||||
|
||||
       [](code_of_conduct.md)
|
||||
|
||||
|
|
@ -11,6 +13,20 @@ This project aims to be a fully featured social network, with a focus on privacy
|
|||
|
||||
> **Note:** This project is not affiliated with Mastodon or Pleroma, and is not a fork of either project. It is a new project built from the ground up.
|
||||
|
||||
## Features
|
||||
|
||||
- [x] Inbound federation
|
||||
- [x] S3 or local media storage
|
||||
- [x] Deduplication of uploaded files
|
||||
- [x] Federation limits
|
||||
- [x] Configurable defaults
|
||||
- [x] Full regex-based filters for posts, users and media
|
||||
- [x] Custom emoji support
|
||||
- [x] Automatic image conversion to WebP or other formats
|
||||
- [ ] Moderation tools
|
||||
- [ ] Full Mastodon API support
|
||||
- [ ] Outbound federation
|
||||
|
||||
## How do I run it?
|
||||
|
||||
### Requirements
|
||||
|
|
@ -26,7 +42,7 @@ This project aims to be a fully featured social network, with a focus on privacy
|
|||
1. Clone this repository
|
||||
|
||||
```bash
|
||||
git clone https://github.com/CPlusPatch/lysand.git
|
||||
git clone https://github.com/lysand-org/lysand.git
|
||||
```
|
||||
|
||||
2. Install the dependencies
|
||||
|
|
@ -35,10 +51,42 @@ git clone https://github.com/CPlusPatch/lysand.git
|
|||
bun install
|
||||
```
|
||||
|
||||
3. Set up a PostgreSQL database
|
||||
3. Set up a PostgreSQL database, using the `pg_uuidv7` extension
|
||||
|
||||
You may use the following [Dockerfile](Postgres.Dockerfile) to set it up:
|
||||
|
||||
```Dockerfile
|
||||
# Use the latest Postgres Docker image based on Alpine
|
||||
FROM postgres:alpine
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
# Install curl
|
||||
RUN apk add --no-cache curl
|
||||
|
||||
RUN cd "$(mktemp -d)" \
|
||||
&& curl -LO "https://github.com/fboulnois/pg_uuidv7/releases/download/v1.3.0/{pg_uuidv7.tar.gz,SHA256SUMS}" \
|
||||
&& tar xf pg_uuidv7.tar.gz \
|
||||
&& sha256sum -c SHA256SUMS \
|
||||
&& PG_MAJOR=$(pg_config --version | sed 's/^.* \([0-9]\{1,\}\).*$/\1/') \
|
||||
&& cp "$PG_MAJOR/pg_uuidv7.so" "$(pg_config --pkglibdir)" \
|
||||
&& cp sql/pg_uuidv7--1.3.sql pg_uuidv7.control "$(pg_config --sharedir)/extension"
|
||||
# Add a script to run the CREATE EXTENSION command
|
||||
RUN echo '#!/bin/sh\npsql -U "$POSTGRES_USER" -d "$POSTGRES_DB" -c "CREATE EXTENSION pg_uuidv7;"' > /docker-entrypoint-initdb.d/init.sh
|
||||
|
||||
# Make the entrypoint script executable
|
||||
RUN chmod +x /docker-entrypoint-initdb.d/init.sh
|
||||
```
|
||||
|
||||
4. Copy the `config.toml.example` file to `config.toml` and fill in the values (you can leave most things to the default, but you will need to configure things such as the database connection)
|
||||
|
||||
5. Run migrations:
|
||||
|
||||
```bash
|
||||
bun migrate
|
||||
```
|
||||
|
||||
### Running
|
||||
|
||||
To run the server, simply run the following command:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue