Back

Restrict Appwrite Console

  • 1
  • Self Hosted
  • Accounts
  • Web
ORIZON
9 Apr, 2023, 17:30

I have a Website at www.example.com and It access appwrite which is hosted on appwrite.example.com. Now anybody can see the Console when they come to the Subdomain. Can I use the Appwrite API to get documents etc but Restrict acces to Appwrite Console?

TL;DR
Issue: Restricting access to the Appwrite Console Solution: 1. Adjust the console frontend source code to dynamically obtain the path instead of hardcoding it. 2. Login to the console is installation-based, not project-based, so there is no unique console path for each project. 3. Changing the console URL path in the configuration file and using Docker Compose can customize the path, similar to how plugins hide the default login page in WordPress. 4. Cloudflare Zero Trust is a free service for up to 50 users that can be used to secure the console endpoint while keeping the API and realtime endpoints open. 5. Using
Drake
9 Apr, 2023, 17:55

It's not because because someone would need to log in to the Console in order to do anything.

ORIZON
9 Apr, 2023, 18:03

Can we Use like a VPN to Connect to the Server and Connect it under LocalHost? So authorized persons can view and Change anything and Others cant even see anything?

Drake
9 Apr, 2023, 18:45

I don't think it's worth it but you can do whatever you want.

Keep in mind, the APIs are still there and it's the same APIs your projects use.

hortigado
9 Apr, 2023, 23:55

but if they still enter they cannot access the panel so they enter the url

Binyamin
10 Apr, 2023, 00:53

One quick solution I've found for this is to use Cloudflare zero trust. Basically it's a service offered by Cloudflare for big enterprises but it's free up to 50 users, which is more the enough in most cases.

You work flow would be something like this.

  1. Move your domain to Cloudflare (it's free)
  2. Open Zero Trust (access) in Cloudflare (It's 100% free)
  3. Make your Appwrite subdomain block in the /console endpoint only.

That's way you will have fully opened Appwrite API & realtime but enterprise grade secured console.

Binyamin
10 Apr, 2023, 00:56

As a reminder active Appwrite server has (not all) these endpoints

  • appwrite.example.com/v1 - API endpoint
  • appwrite.example.com/console - Console endpoint
  • appwrite.example.com//v1/realtime - Realtime endpoint
  • appwrite.example.com/login | signup etc - Console user management endpoints

And although you won't be able to block the console user management endpoints because doing so you will also block your API. but blocking the console would be a great solution for 99.99% of the time

Mattias Aabmets
25 Apr, 2023, 19:18

Why is it not possible to set the console url path in the conf file and then docker compose up that change into appwrite, so that the console would be no longer on the default /console path, but whatever was defined in the conf file, like /jdbwljeowncj for instace? WordPress has got plugins to hide the default wp-admin login page. Why not Appwrite also?

Drake
25 Apr, 2023, 19:38
  1. it might be difficult to get the Console (a single page app) to work correctly after changing the path
  2. Most of the APIs used in the Console are the same APIs used by any other project so you can't really block them.
Mattias Aabmets
26 Apr, 2023, 04:54
  1. If the app can work at /console, it can work at any path, the console frontends source code just needs to be adjusted to be able to dynamically obtain the path from somewhere, not have it hardcoded into itself.
  2. I don't really understand the second issue. The login to the console is installation-based, not project based. Each project does not have a unique console path, all projects are managed from under a single login. So how is this an issue?
Drake
26 Apr, 2023, 05:02

I don't want to clutter this thread more. Feel free to create a new <#1072905050399191082> post

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more