Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Issue with file uploads #101

Closed
mirkohubtv opened this issue Oct 2, 2024 · 9 comments · Fixed by #112
Closed

Bug: Issue with file uploads #101

mirkohubtv opened this issue Oct 2, 2024 · 9 comments · Fixed by #112
Labels
bug Something isn't working

Comments

@mirkohubtv
Copy link

What happened?

Hi there,

I’m trying to self-host Revolt following the official repository on my Windows 11 machine with Docker.

Everything is working fine except for the file uploads (Autumn endpoint). I’ve followed the guide step by step and tried multiple solutions, but after hours of debugging, I still can’t figure out what’s causing the issue.

If anyone has experience with this or can point me in the right direction, I’d greatly appreciate it. I’ve been stuck for quite some time, and I’m running out of ideas. I’m also open to a Discord or Revolt call if that makes troubleshooting easier.

Thanks in advance for any help!

image
image

@mirkohubtv mirkohubtv added the bug Something isn't working label Oct 2, 2024
@github-project-automation github-project-automation bot moved this to 🆕 Untriaged in Revolt Project Oct 2, 2024
@insertish
Copy link
Member

What image tag of autumn are you using?

@mirkohubtv
Copy link
Author

Reference in

The latest, i just used the git clone command and docker compose up

git clone https://github.com/revoltchat/self-hosted revolt
cd revolt
cp .env.example .env
wget -O Revolt.toml https://raw.githubusercontent.com/revoltchat/backend/main/crates/core/config/Revolt.toml
docker compose up

@FifthSparrow
Copy link

FifthSparrow commented Oct 4, 2024

I am also getting this same issue (except with a status error of 500) with autumn:1.1.11 on a fresh install.

Unrelated to this error, but files.s3.default_bucket in Revolt.toml should probably be renamed from "revolt-uploads" to "attachments". And the caddyfile should use port 3000 instead of 14704 for autumn:1.1.11. It seems that the latest container images for autumn after 1.1.11 are now using port 14704, but they seem to error out for me when I try to docker run them:

$ docker run ghcr.io/revoltchat/autumn:20241002-7
 INFO  revolt_config > Starting revolt-autumn@0.7.18
 ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" }

@mirkohubtv
Copy link
Author

I am also getting this same issue (except with a status error of 500) with autumn:1.1.11 on a fresh install.

Unrelated to this error, but files.s3.default_bucket in Revolt.toml should probably be renamed from "revolt-uploads" to "attachments". And the caddyfile should use port 3000 instead of 14704 for autumn:1.1.11. It seems that the latest container images for autumn after 1.1.11 are now using port 14704, but they seem to error out for me when I try to docker run them:

$ docker run ghcr.io/revoltchat/autumn:20241002-7
 INFO  revolt_config > Starting revolt-autumn@0.7.18
 ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" }

I solved my issue by running autumn in a separate instance, you may try it. We need to wait a fix.

@FifthSparrow
Copy link

I solved my issue by running autumn in a separate instance, you may try it. We need to wait a fix.

Do you mean running autumn as a separate docker container outside the docker compose.yaml file? Could you please share how you configured that?

@mirkohubtv
Copy link
Author

mirkohubtv commented Oct 5, 2024

I solved my issue by running autumn in a separate instance, you may try it. We need to wait a fix.

Do you mean running autumn as a separate docker container outside the docker compose.yaml file? Could you please share how you configured that?

Sure.

git clone https://github.com/revoltchat/autumn.git autumn
cd autumn
cargo build
export AUTUMN_HOST="0.0.0.0:8081"
export AUTUMN_MONGO_URI="YOUR_MONGODB_URI"
cargo run

You may proxy via nginx the port 8081 like autumn.example.com and configurate it on Revolt .env/.toml files

AUTUMN_PUBLIC_URL=https://autumn.example.com

And that's it. You now can upload files. If you need more help with setup feel free to contact me on Revolt MirkoHubTV#8516 or Discord: mirkohubtv.

@FifthSparrow
Copy link

I solved my issue by running autumn in a separate instance, you may try it. We need to wait a fix.

Do you mean running autumn as a separate docker container outside the docker compose.yaml file? Could you please share how you configured that?

Sure.

git clone https://github.com/revoltchat/autumn.git autumn
cd autumn
cargo build
export AUTUMN_HOST="0.0.0.0:8081"
export AUTUMN_MONGO_URI="YOUR_MONGODB_URI"
cargo run
You may proxy via nginx the port 8081 like autumn.example.com and configurate it on Revolt .env/.toml files

AUTUMN_PUBLIC_URL=https://autumn.example.com
And that's it. You now can upload files. If you need more help with setup feel free to contact me on Revolt MirkoHubTV#8516 or Discord: mirkohubtv.

@mirkohubtv Thank you! That worked. For anyone who wants to do that using docker:

docker run -it --name autumn_container \
  -p 3000:3000 \
  -v autumn_data:/data \
  -e AUTUMN_HOST="0.0.0.0:3000" \
  -e AUTUMN_MONGO_URI="YOUR_MONGODB_URI" \
  rust:latest /bin/sh -c "
    apt-get update -y && apt-get upgrade -y && apt-get install -y git pkg-config libssl-dev && \
    git clone https://github.com/revoltchat/autumn.git /autumn && \
    cd /autumn && \
    cargo build --release && \
    cargo run --release
  "

@JoCat
Copy link

JoCat commented Oct 8, 2024

Changing the port for autumn to 3000 in Caddyfile worked for me

@kotazzz
Copy link

kotazzz commented Oct 9, 2024

Changing the port for autumn to 3000 in Caddyfile worked for me

Me too. Thank you for help

@github-project-automation github-project-automation bot moved this from 🧑‍💻 Needs Reproduction to ✅ Done in Revolt Project Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

5 participants