I'm using docker swarm and deploy compose file with stack.
I checked executor container has proper _APP_EXECUTOR_RUNTIME_NETWORK
and OPEN_RUNTIMES_NETWORK
environment variable.
But my openruntimes container does not joined into appwrite_runtimes
network automatically.
Solve with following instructions
- Create network manually
docker network create -d overlay --attachable appwrite_runtimes
- Use external network in compose file
networks:
runtimes:
external: true
name: appwrite_runtimes
When using swarm mode, appwrite_runtimes cannot attachable manually so it missing when create openruntimes container
You'll need to do the networks overlay and attachable
You can check this https://book.appread.io/docker-swarm And the Swarm file here https://github.com/byawitz/scaling-appwrite/tree/main/swarm
Can you run the
docker network inspect appwrite_runtimes
Also, when deploying Docker swarm the appwrite-executor
can't be scaled
You can see at the chapter I've referenced here And here in the note https://book.appread.io/benchmarks#docker-swarm
Thanks for the link, i will read all of it
👍 Notice that this approach I've wrote use the a decentralizated Database and storeage https://book.appread.io/decentralization
I think that the compose file in the github will generate containers without any environment variables
Since swarm mode does not use .env files
It don't use the env_file
approach rather a different one
Check here
https://book.appread.io/docker-swarm#deploying-the-stack
By running this command
export $(grep -v '^#' .env | xargs) && docker stack config -c docker-compose.yml
That will put all the .env
variables in the path
So when you're deploying the task it will use all the environment variables
I used source .env
but it was not work.
I'm too noob to shell scripting. 😆
Try that approach and let me know if it worked
Working with export $(...)
very interesting
It goes like this
grep -v '^#' .env
will output all the variables inside the.env
filexargs
will run the command onexport
on each of the values.
And unlike source
, export
pass values to commands so it still exists while executing docker commands
Yes and no
When running export linux
will add the value into the system environment which you can find by running
env
source
on the other hand runs the list of bash
inside a given file.
oh...
after export $()
, env
shows include .env definitions but source does not
Yes
[SOLVED] executor does not deploy openruntimes container with proper network
Recommended threads
- Realtime with multiple connections
I need the Realtime on multiple Collections for diffrent applicational logic. So my question is: Is there a way to have only 1 Websocket connection or do I need...
- Can't login or deploy functions in Appwr...
Hello, since i updatet to the appwrite cli 6.1.0 i can't login or deploy functions with the cli. When i call the command: "appwrite get account --verbose" i ge...
- Create admin user?
I'm not really sure how this is supposed to work, I installed Appwrite through docker-compose and set it up. When I launched the app and went into it, I created...