Back

[SOLVED] Could not resolve host while building a function on 1.4.0 and 1.4.1

  • 0
  • Functions
obiwanzenobi
31 Aug, 2023, 12:22

I restarted multiple times btw

TL;DR
The user faced the issue of "Could not resolve host" while building a function on version 1.4.0 and 1.4.1. The solution was to change the `_APP_EXECUTOR_HOST` to either "http://executor/v1" or "http://openruntime-executor/v1". They also needed to change the `_APP_EXECUTOR_RUNTIME_NETWORK` to "runtimes" in the `docker-compose.yml` file. After making these changes, they needed to reload the compose and restart multiple times.
Binyamin
31 Aug, 2023, 14:23

In the newer docker-compose.yml file the network changed

TypeScript
networks:
  gateway:
    name: gateway
  appwrite:
    name: appwrite
  runtimes:
    name: runtimes

So make sure the _APP_EXECUTOR_RUNTIME_NETWORK is set to runtimes

TypeScript
-_APP_EXECUTOR_RUNTIME_NETWORK=appwrite_runtimes
+_APP_EXECUTOR_RUNTIME_NETWORK=runtimes
Binyamin
31 Aug, 2023, 14:23

After that reload your compose

Binyamin
31 Aug, 2023, 14:23

And check again

obiwanzenobi
31 Aug, 2023, 15:19

and what about other? 'runtimes' should be everywhere?

TypeScript
_APP_EXECUTOR_RUNTIME_NETWORK=runtimes
_APP_FUNCTIONS_ENVS=dart-3.0
_APP_FUNCTIONS_INACTIVE_THRESHOLD=60
DOCKERHUB_PULL_USERNAME=
DOCKERHUB_PULL_PASSWORD=
DOCKERHUB_PULL_EMAIL=
OPEN_RUNTIMES_NETWORK=appwrite_runtimes
_APP_FUNCTIONS_RUNTIMES_NETWORK=runtimes
obiwanzenobi
31 Aug, 2023, 15:19

OPEN_RUNTIMES_NETWORK

Binyamin
31 Aug, 2023, 15:20

Most of them are deprecated

Binyamin
31 Aug, 2023, 15:20

Take a look in the docker-compose file to see which one is in use

Binyamin
31 Aug, 2023, 15:21

Also. You'll probably need to change the host

Binyamin
31 Aug, 2023, 15:21

I could check it later

obiwanzenobi
31 Aug, 2023, 15:23

host? which param name is that?

obiwanzenobi
31 Aug, 2023, 15:28

still the same problem after changing to runtimes

Binyamin
31 Aug, 2023, 15:28

App exexutor host

Binyamin
31 Aug, 2023, 15:29

I think the url should be changed to ...openruntime-exexutor... or just ...executor...

Binyamin
31 Aug, 2023, 15:29

Try them both

obiwanzenobi
31 Aug, 2023, 15:34

have to go now but i will test in 2h

obiwanzenobi
31 Aug, 2023, 18:11

by default there is _APP_EXECUTOR_HOST=http://appwrite-executor/v1

obiwanzenobi
31 Aug, 2023, 18:13

Could not resolve host: openruntime-executor with status code 0

obiwanzenobi
31 Aug, 2023, 18:13

it was for _APP_EXECUTOR_HOST=http://openruntimes-executor/v1 trying just executor

obiwanzenobi
31 Aug, 2023, 18:16

executor works

obiwanzenobi
31 Aug, 2023, 18:16

i will upload config for everybody that have a problem

obiwanzenobi
31 Aug, 2023, 18:19
TypeScript
_APP_DOMAIN_FUNCTIONS=
_APP_FUNCTIONS_SIZE_LIMIT=30000000
_APP_FUNCTIONS_TIMEOUT=900
_APP_FUNCTIONS_BUILD_TIMEOUT=900
_APP_FUNCTIONS_CONTAINERS=10
_APP_FUNCTIONS_CPUS=0
_APP_FUNCTIONS_MEMORY=0
_APP_FUNCTIONS_MEMORY_SWAP=0
_APP_FUNCTIONS_RUNTIMES=dart-3.0

_APP_EXECUTOR_HOST=http://executor/v1
_APP_EXECUTOR_RUNTIME_NETWORK=runtimes
_APP_FUNCTIONS_ENVS=dart-3.0
_APP_FUNCTIONS_INACTIVE_THRESHOLD=60

OPEN_RUNTIMES_NETWORK=runtimes
_APP_FUNCTIONS_RUNTIMES_NETWORK=runtimes
obiwanzenobi
31 Aug, 2023, 18:19

Thanks for help Binyamin!

obiwanzenobi
31 Aug, 2023, 18:19

[SOLVED] Could not resolve host while building a function on 1.4.0 and 1.4.1

Binyamin
31 Aug, 2023, 18:32

Great 👍

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