this post was submitted on 09 Jun 2023
28 points (100.0% liked)

Lemmy.World Announcements

29026 readers
6 users here now

This Community is intended for posts about the Lemmy.world server by the admins.

Follow us for server news ๐Ÿ˜

Outages ๐Ÿ”ฅ

https://status.lemmy.world

For support with issues at Lemmy.world, go to the Lemmy.world Support community.

Support e-mail

Any support requests are best sent to [email protected] e-mail.

Report contact

Donations ๐Ÿ’—

If you would like to make a donation to support the cost of running this platform, please do so at the following donation URLs.

If you can, please use / switch to Ko-Fi, it has the lowest fees for us

Ko-Fi (Donate)

Bunq (Donate)

Open Collective backers and sponsors

Patreon

Join the team

founded 1 year ago
MODERATORS
 

When you visit http://lemmy.world it should redirect to https://lemmy.world - at least the login page should be secure.

you are viewing a single comment's thread
view the rest of the comments
[โ€“] [email protected] 3 points 1 year ago (1 children)

You could try this

this config snippet is assuming thet you've already got the TLS cert/pem file for lemmy.world elsewhere in your nginx.config

http {
  server {
    listen 80;
    listen 443 ssl;
    server_name lemmy.world;

    if ($scheme = "http") {
        return 307 https://$host$request_uri;
    }

    location / {
        proxy_pass http://lemmy-ui:1234;
        proxy_set_header Host $host;
    }
}

If you get redirected to lemmy.world:1234, then add absolute_redirect off; in the 'server' block

Last thing - 307 is a temporary redirect, you might to change it to a permanent one once you've confirmed it's working as intended

[โ€“] ruud 2 points 1 year ago

Cool, thanks! I'll try that.