Quantcast
Channel: Active questions tagged https - Stack Overflow
Viewing all articles
Browse latest Browse all 1858

How to self host Supabase with Docker on HTTPS? [closed]

$
0
0

I have decided to self host Supabase via Docker. However, my experience with docker is pretty low. So I am probably making some rookie mistakes here.

I am able to run all the containers of supabase which were defined in the docker-compose.yml file as an example. https://github.com/supabase/supabase/blob/master/docker/docker-compose.yml

So at this point I am able to get to all the functionality with the public IP of my VM like this:

To make it a bit more user friendly, I created a subdomain abc.example.com and pointed its A records to the IP address of my VM. So far so good.

However, I would like to make the containers accessible only via HTTPS to make it a bit safer. Therefore I found on the internet two solutions.

  1. Using Kong ( https://towardsdev.com/self-hosted-supabase-with-lets-encrypt-certificate-for-kong-2a6a8dd298db ) , but this explanation is not that good in my opinion. At least not for a beginner in Docker like me
  2. Using Traefik. By adding the following labels to the Kong container docker-compose.yml, all my problems would be solved (surprise, this is not the case).

:

  labels:    - "traefik.enable=true"    - "traefik.http.routers.kong.rule=Host(`abc.example.com`)"    - "traefik.http.routers.kong.entrypoints=websecure"    - "traefik.http.routers.kong.tls=true"    - "traefik.http.routers.kong.tls.certresolver=letsencrypt"    - "traefik.http.services.kong.loadbalancer.server.port=8000"

In option 2, the https://abc.example.com works perfectly, as it shows me the Supabase Studio, but the https://abc.example.com/functions/v1/hello does not return the string. It's still on the Studio app/container, but with an error page since there is no functions/v1/hello path defined in Studio.

What option is best/easiest to get https working for all the running Supabase containers?


Viewing all articles
Browse latest Browse all 1858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>