this post was submitted on 15 Jun 2023
5 points (85.7% liked)

Selfhosted

40154 readers
597 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Hey, does anyone else have issues running a lemmy instance with docker compose?

I cant get it to work. I followed the guide on the wiki step by step to no avail..

Edit: This is my error message with the docker-compose config as provided by the guide:

Then I tried to remove the logging bits, I get this error:

Then I started over and pulled the github repository and edited the files in the docker subfolder and I get this error:

I give up πŸ™‚

top 10 comments
sorted by: hot top controversial new old
[–] [email protected] 3 points 1 year ago (1 children)

Have you tried the Ansible playbook?

[–] [email protected] 2 points 1 year ago (1 children)

I've never really used Ansible before. Is it difficult? At first glance it's little overwhelming

[–] [email protected] 1 points 1 year ago

It’s extremely easy. Highly recommend it.

[–] [email protected] 2 points 1 year ago (2 children)

Can you send you docker-compose file?

[–] [email protected] 3 points 1 year ago

Are you planning on modifying the lemmy backed or UI? If not I would suggest:

  1. Comment out the sections about building the image from scratch.
  2. Go to dockerhub and find the newest tag that matches your system's architecture and use that instead.

If you can paste your docker-compose file we can more precisely tell you what needs to be changed.

The default config expects that your cloning the entire GitHub repo, for the backend, at least, and tries to compile it from scratch. You can instead just tell docker to use a precompiled image instead.

Lastly YAML is very picky about whitespace so something might be indented incorrectly. So again, if we can see your docker-compose file we might be able to see what's wrong.

[–] [email protected] 2 points 1 year ago* (last edited 1 year ago) (4 children)

I used the docker-compose file from the official github repo: https://github.com/LemmyNet/lemmy/blob/main/docker/docker-compose.yml

But after the comment from @[email protected] I changed it to pull the image from dockerhub instead of building it myself. Now it pulls correctly and the server comes online but is almost unusable. The homepage displays but I cannot login as admin or create a new user :/

Edit: Here is the docker-compose.yml I used

[–] [email protected] 2 points 1 year ago* (last edited 1 year ago)

Don't pull dev use 0.17.4

lemmy: image: dessalines/lemmy:dev

lemmy: image: dessalines/lemmy:0.17.4

Also in your Pictrs environment you may need:

- PICTRS__SERVER__ADDRESS=0.0.0.0:8080

Lastly did you do the following before runing your docker-compose up -d cmd?

mkdir -p volumes/pictrs sudo chown -R 991:991 volumes/pictrs

[–] [email protected] 2 points 1 year ago

3rd reply :)

Have you edited your lemmy.hjson yet to ensure details match the docker-compose.yml? The instructions for that part are not very clear and I had to do lots of trial and error to get it working.

[–] [email protected] 2 points 1 year ago* (last edited 1 year ago)

Also, @[email protected], what does your nginx.conf look like? Now that the webpage is loading, the backend might be blocked/not configured properly in nginx, so nginx isn't properly forwarding requests to the backend.

[–] [email protected] 1 points 1 year ago

2nd reply, can you also post the logs from the lemmy-lemmy-1, lemmy-lemmy-ui-1, lemmy-postgres-1, and lemmy-pictrs-1 containers?

I found most of my issues were dealing with communication between networks and IP's binding wrong which wont show anywhere but in the logs as connection issues.

load more comments
view more: next β€Ί