Back

Appwrite functions with ngrok

  • 0
  • Functions
shamanth
3 Oct, 2023, 10:09

I setup appwrite self hosting on my machine and followed the docs to setup appwrite functions. It suggested to use ngrok as proxy if running on localhost. But the domain assigned to the function is not accessible. Any suggestions?

TL;DR
The user is asking for clarification on how to set up ngrok with Appwrite functions. They are wondering if the two domains (_APP_DOMAIN_TARGET and _APP_DOMAIN_FUNCTIONS) can be the same. Other users explain that the functions domain needs to be a different domain and suggest creating a specific endpoint for each function. The user also asks about SSL on the server end and is told that it may not be necessary for ngrok. They ask for further resources but are told that ngrok may not work with the custom domain function due to the lack of an SSL certificate. The user then asks for recommendations on alternative solutions and is advised to try
IAmWhatIAm
3 Oct, 2023, 11:19

What happens when you proceed from this selfsigned ssl warning?

shamanth
3 Oct, 2023, 11:41

There's no proceed option

Drake
3 Oct, 2023, 13:51

You can't use ngrok with the custom domain function because there is no SSL certificate

Drake
3 Oct, 2023, 13:52

Type thisisunsafe

shamanth
3 Oct, 2023, 13:55

I was working on an issue which requires Deno runtime which is not available in cloud version. The function acts like a webhook receiver... so need a public endpoint. If not ngrok what would you suggest🤒

shamanth
3 Oct, 2023, 14:00
shamanth
3 Oct, 2023, 14:01

Yep...it doesn't work ... Only self hosted appwrite is accessible through ngrok

Drake
3 Oct, 2023, 14:02

You might need a custom domain...or you can try setting up another ngrok tunnel and using that as a custom domain

shamanth
3 Oct, 2023, 14:18

Do you have any resources/docs to augment my understanding. Regrettably my knowledge in this topic is inadequate

Drake
3 Oct, 2023, 14:20

Not really. To explain further, you have an ngrok tunnel for one specific domain. The function domain is a different domain so it's not pointing anywhere

IAmWhatIAm
3 Oct, 2023, 14:24

we need to create a specific endpoint for each function and validate , then add the corresponding subdomain CNAME to DNS of the main domain.

hope my understanding is correct

I use cloudflare tunnel, for that too we need SSL on server end??

Drake
3 Oct, 2023, 14:25

Yes. Although some services set up an SSL cert for you so the certificate in appwrite may not be required

IAmWhatIAm
3 Oct, 2023, 14:28

got it. bcoz I am lazy lolz 😛

IAmWhatIAm
3 Oct, 2023, 14:31

btw, these two cant be same right? _APP_DOMAIN_TARGET= _APP_DOMAIN_FUNCTIONS

valid will be _APP_DOMAIN_TARGET=appwrite.text.xyz _APP_DOMAIN_FUNCTIONS=functions.text.xyz

?? in that case all functions will be 17264326.functions.text.xyz ??

Drake
3 Oct, 2023, 14:32

They can be the same

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