Commit graph

655 commits

Author SHA1 Message Date
Dessalines 63d3759c48 Version 0.18.0 2023-06-23 08:41:20 -04:00
Nutomic 434beadb58
Use Rust 1.70 for Docker and CI (#3265) 2023-06-22 07:46:07 -04:00
ShittyKopper 862ceefc56
docker-compose: Add init to UI (#3248)
* docker-compose: Add init to UI

Prevents waiting 10 seconds to shutdown

* docker-compose: Update to version 3.7
2023-06-22 10:22:15 +02:00
Dessalines d4f52b78b3
Trying to fix version again. (#3246) 2023-06-21 21:46:32 +02:00
Dessalines b214d3dc00
Adding current domain from settings to CORs. (#3231) 2023-06-20 20:29:48 -04:00
Nutomic b37c30ffae
Move cors default to source code (#3219) 2023-06-20 11:19:03 -04:00
Andrew DeLisa bfc0c0e7d3
fix: add CORS origin environment variable (#3191)
* fix: add CORS origin environment variable

* chore: formatting

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-20 08:29:38 -04:00
Edgar Alvarado c32585b034
Docker yaml anchors and docker logs (#3027)
* Use anchor for duplicated compose properties

* Include docker log max

* Run prettier
2023-06-13 08:37:06 -04:00
Edgar Alvarado 932e65c16d
Fix ports used by docker (#3012)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-12 18:38:27 -04:00
Charles Hall 4e5798852f
make shebangs posix compliant (#2974)
Previously, these scripts wouldn't work on exotic systems such as NixOS.

```
fd '\.sh$' -t f --exec sed -i 's@#!/bin/bash@#!/usr/bin/env bash@'
```
2023-06-08 15:38:26 -04:00
Jason Watkins 491e197529
Add lemmyexternalproxy to lemmy so that it can talk to the internet (#2960)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-06-08 08:30:16 -04:00
Dessalines af03dcfeac
Fix dev setups. (#2944) 2023-06-06 22:22:21 -04:00
Justin Gauthier d439bdf8b4
Update to fix nginx proxy config for Docker Installs (#2908)
* Update to fix nginx proxy config

* Update docker-compose.yml - fix type

---------

Co-authored-by: Jax Gauthier <jax@gauthier.id>
2023-06-05 12:43:31 +02:00
Nutomic 1b4f995706
Remove jaeger, opentelemetry from docker-compose (#2894) 2023-06-04 22:16:49 +02:00
SleeplessOne1917 e856eda74d
Fix typo that caused error (#2861) 2023-05-14 14:02:05 -04:00
SleeplessOne1917 0379c9e4c1
Make volumes used in docker compose work when running on machines with SELinux enabled (#2853)
* Make volumes used in docker compose work when running on machines with SELinux enabled

* Switch lemmy-ui comments

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-05-11 20:15:12 -04:00
Dessalines 1b5437cbe3
Addressing slow profile queries. #2777 (#2830)
* Addressing slow profile queries. #2777

* Addressing PR comments.
2023-04-25 19:28:06 -04:00
Dessalines 17527d0e7e
Reverting to older non-multi-arch dockerfile. Fixes #2832 (#2833) 2023-04-25 22:40:58 +02:00
6543 85ef507ac7
Use Dockerfile.multiarch as Dockerfile (#2818)
* use Dockerfile.multiarch and delete old Dockerfile

* Dockerfile.multiarch -> Dockerfile

* nit
2023-04-18 22:21:31 +02:00
SleeplessOne1917 f5511cfd25
Make path to local lemmy-ui use correct relative path (#2817) 2023-04-17 13:38:59 -04:00
6543 90c6dc2732
Use official rust image and clean up Dockerfiles (#2804)
* Add docker/Dockerfile.multiarch

* Update normal Dockerfile to be similar to multiarch one

* docker build run on x86 and arm64 now
manifest not needed, its handled by buildx plugin

* Rename Dockerfile.arm To Dockerfile.debian

* Emulate builder on arm target too

* fix misspell

* Improve Dockerfiles

* naming

* undo multiarchbuild settings as its blocked by a dependeny, see #2806

* Delete Dockerfile.debian
2023-04-16 12:56:12 -04:00
Nutomic 6f513793cb
Activitypub crate rewrite (#2782)
* update activitypub-federation crate to 0.4.0

* fixes

* apub compiles!

* everything compiling!

* almost done, federated follow failing

* some test fixes

* use release

* add code back in
2023-03-21 16:03:05 +01:00
Anon 6bc49bdd70
Add Custom Emojis Support (#2616)
* Add Custom Emojis

* Modify index
2023-03-20 17:32:31 -04:00
Nutomic 62663a9f2e
Implement separate mod activities for feature, lock post (#2716)
* Implement separate mod activities for feature, lock post

Also includes collection for featured posts. Later we also need
to do the same for Comment.distinguished

* some changes

---------

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2023-02-18 09:50:28 -05:00
Dessalines 47f4aa3550
Fixing slow joins to post_read, post_saved, and comment_saved . (#2738)
- Fixes #2445
2023-02-18 09:35:35 -05:00
Dessalines 993489a80f
Combine prod and dev docker setups using build-arg (#2739)
* Combine prod and dev docker setups using build-arg

- Fixes #2603

* Dont use cache for release build.
2023-02-17 15:29:45 +09:00
Nutomic 2891856b48
Fix docker federation setup (#2706) 2023-02-05 12:30:10 -05:00
Dessalines 5ae409d4e4 Version 0.17.1 2023-02-03 09:36:18 -05:00
Dessalines 53bc0311b1 Version 0.17.0 2023-01-31 08:30:54 -05:00
Dessalines a610211557
Fixing .drone.yml (#2677)
* Try to fix docker/drone plugin

* Trying to use one rust image.

* Fixing drone 1.

* Fixing drone 2.

* Add drone notify.

* Fixing drone 3.

* Fixing drone 4.

* Fix clippy.

* Remove uninlined format lint.

* Combine all cargo tasks

* Fixing drone 5.

* Fixing drone 6.

* Fixing drone 7.

* Fixing drone 8.

* Fixing drone 9.

* Fixing drone 10.

* Fixing drone 12.

* Fixing drone 13.

* Fixing drone 14.

* Fixing drone 15.

* Fixing drone 16.

* Fixing drone 17.

* Fixing drone 18.

* Fixing drone 19.

* Fixing drone 20.

* Fixing drone 21.

* Fixing drone 22.

* Fixing drone 23.

* Fixing drone 24.

* Fixing drone 25.

* Fixing drone 26.

* Fixing drone 27.

* Fixing drone 28.

* Fixing drone 29.

* Fixing drone 30.

* Fixing drone 31.

* Fixing drone 32.

* Fixing drone 33.

* Fixing drone 34.

* Fixing drone 35.

* Fixing drone 36.

* Fixing drone 37.

* Fixing drone 38.

* Fixing drone 39.

* Fixing drone 40.

* Fixing drone 41.

* Fixing drone 43.

* Fixing drone 44.

* Fixing drone 45.

* Last cleanup.

* Fixing drone 46.

* Separate ci steps (#2679)

* separate ci steps

* fix 1

* add comments

* dont add rustfmt explicitly

* Revert "dont add rustfmt explicitly"

This reverts commit 358ce3302a134b7ac88d90a854079356995e9725.

* dont use all features for tests

---------

Co-authored-by: Nutomic <me@nutomic.com>
2023-01-30 14:17:24 -05:00
Dessalines 70c549dad8
Speeding up comment-ltree migration, fixing index creation. Fixes #2664 (#2670)
* Speeding up comment-ltree migration, fixing index creation. Fixes #2664

* Adding some logging lines, fixing for missing posts.

* Adding more postgres config
2023-01-23 09:59:25 -05:00
Dessalines ac56504291
Upgrade to postgres 15. (#2659) 2023-01-20 18:15:07 +01:00
Dessalines 76e0ab934f
Fixing missing forms, incorrect user discussion_languages (#2580)
* Fixing missing forms, incorrect user discussion_languages

* Add discussion_language to CommunityResponse

* Adding discussion_languages to CommunityResponse

* Adding discussion_language logic to community.create
2022-12-19 11:40:22 +00:00
Dessalines 5d837780f5
Add diesel_async, get rid of blocking function (#2510)
* Moving settings to Database.

- Moves many settings into the database. Fixes #2285
- Adds a local_site and instance table. Fixes #2365 . Fixes #2368
- Separates SQL update an insert forms, to avoid runtime errors.
- Adds TypedBuilder to all the SQL forms, instead of default.

* Fix weird clippy issue.

* Removing extra lines.

* Some fixes from suggestions.

* Fixing apub tests.

* Using instance creation helper function.

* Move forms to their own line.

* Trying to fix local_site_data, still broken.

* Testing out async

* Testing out async 2

* Fixing federation tests.

* Trying to fix check features 1.

* Starting on adding diesel async. 1/4th done.

* Added async to views and schema.

* Adding some more async

* Compiling now.

* Added diesel async. Fixes #2465

* Running clippy --fix

* Trying to fix cargo test on drone.

* Trying new muslrust.

* Trying a custom dns

* Trying a custom dns 2

* Trying a custom dns 3

* Trying a custom dns 4

* Trying a custom dns 5

* Trying a custom dns 6

* Trying a custom dns 7

* Addressing PR comments.

* Adding check_apub to all verify functions.

* Reverting back drone.

* Fixing merge

* Fix docker images.

* Adding missing discussion_languages.

* Trying to fix federation tests.

* Fix site setup user creation.

* Fix clippy

* Fix clippy 2

* Test api faster

* Try to fix 1

* Try to fix 2

* What are these lines about

* Trying to fix 3

* Moving federation test back to top.

* Remove logging cat.
2022-11-09 10:05:00 +00:00
Nutomic 28eade6168
Fix invalid config in docker/prod (fixes #2520) (#2524) 2022-11-02 18:50:09 +00:00
Nutomic 3b0be52e67
Image improvements (#2513)
* Image improvements

* remove rate limits
2022-10-28 14:34:40 +00:00
Dessalines 235cc8b228
Moving settings to Database. (#2492)
* Moving settings to Database.

- Moves many settings into the database. Fixes #2285
- Adds a local_site and instance table. Fixes #2365 . Fixes #2368
- Separates SQL update an insert forms, to avoid runtime errors.
- Adds TypedBuilder to all the SQL forms, instead of default.

* Fix weird clippy issue.

* Removing extra lines.

* Some fixes from suggestions.

* Fixing apub tests.

* Using instance creation helper function.

* Move forms to their own line.

* Trying to fix local_site_data, still broken.

* Fixing federation tests.

* Trying to fix check features 1.

* Addressing PR comments.

* Adding check_apub to all verify functions.
2022-10-27 09:24:07 +00:00
Nutomic 276a8c2bd3
Enable lto, strip symbols via cargo.toml (#2512) 2022-10-25 15:10:07 +00:00
Dessalines 9ac13a0891
Fix docker dev build (#2509)
* Fixing docker dev build.

* Remove volume mount files.

* Fixing pictrs.

* Addressing PR comments.
2022-10-21 15:13:24 +00:00
sam365724 cb559178bd
More real-world prod config, separate lemmy config (#2487) 2022-10-10 16:06:52 +00:00
sam365724 d2608bb279
Make docker-compose more clear and explicit (#2469)
* Make docker-compose more clear, starting with dev

Explicit networks, not opining ports when not necessary: Confusing for users. All requests go through nginx, so there is no need to open ports directly on pictrs and other services for example. I wasn't sure about jaeger and otel, maybe that can be changed somewhat too. 

Also adding comments and things that are relevant for a prod setup too.

* Update with comments

* Providing dedicated nginx and lemmy conf

* Fix config key for pictrs.

* Fix config key for pictrs.

* updates on naming

* Adding docker compose build info

* Revert to more complete lemmy config

* Test and fix build paths

* Fix otel config

* Delete dev file

Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
2022-10-06 19:01:19 +00:00
Dessalines 2f0560ca3f
Update docker version to 0.16.6. Fixes #2435 (#2438) 2022-09-12 09:33:49 +00:00
Dessalines f878151648
Add postgres auto-explain for dev testing. (#2399)
* Add postgres auto-explain for dev testing.

* add newline

* fix indent

Co-authored-by: Nutomic <me@nutomic.com>
2022-08-16 12:22:29 +00:00
Dessalines 9c3efe32e7
First pass at adding comment trees. (#2362)
* First pass at adding comment trees.

- Extracted comment replies into its own table.
- Added ltree column to comment
- Added parent_id param to GetComments to fetch a tree branch
- No paging / limiting yet

* Adding child_count to comment_aggregates.

* Adding parent comment update counts

* Fix unit tests.

* Comment tree paging mostly done.

* Fix clippy

* Fix drone tests wrong postgres version.

* Fix unit tests.

* Add back in delete in unit test.

* Add postgres upgrade script.

* Fixing some PR comments.

* Move update ltree into Comment::create

* Updating based on comments.

* Fix send soft fail.
2022-07-30 05:55:59 +02:00
Nutomic 42eac1560f
Remove docker/pleroma/ folder (#2381) 2022-07-29 08:37:23 -04:00
Dessalines 4e12e25c59
Adding admin purging of DB items and pictures. #904 #1331 (#1809)
* First pass at adding admin purge. #904 #1331

* Breaking out purge into 4 tables for the 4 purgeable types.

* Using CommunitySafe instead in view

* Fix db_schema features flags.

* Attempting to pass API key.

* Adding pictrs image purging

- Added pictrs_config block, for API_KEY
- Clear out image columns after purging

* Remove the remove_images field from a few of the purge API calls.

* Fix some suggestions by @nutomic.

* Add separate pictrs reqwest client.

* Update defaults.hjson

Co-authored-by: Nutomic <me@nutomic.com>
2022-06-13 19:15:04 +00:00
Nutomic a29cf04092
Fix lemmy version in prod docker-compose.yml (#2304) 2022-06-08 11:48:36 -04:00
Nutomic fcaf7a084c
Upgrade activitypub_federation to 0.2.0, add setting federation.debug (#2300) 2022-06-08 11:45:39 -04:00
Dessalines 1bd57ee5ca Version 0.16.5 2022-05-30 18:32:31 -04:00
Nutomic 7566f325cd
Downgrade Rust Docker images to 1.59 to fix CI failures (ref #2263) (#2274) 2022-05-20 13:29:04 +00:00