Rank 1: Thread
and I've done that, and they all start, and look happy from their logs, but when I run migrate, I get the swoole error
Votes
0
Replies
24
Participants
Unknown
Messages
25
Rank 1: Thread
and I've done that, and they all start, and look happy from their logs, but when I run migrate, I get the swoole error
Rank 1: Thread
This is the full error
Fatal error: Uncaught Swoole\Error: API must be called in the coroutine in /usr/src/code/app/init.php:928Stack trace:#0 /usr/src/code/app/init.php(928): PDO->__construct('mysql:host=mari...', 'apps', Object(SensitiveParameterValue), Array)#1 /usr/src/code/vendor/utopia-php/registry/src/Registry/Registry.php(75): {closure}()#2 /usr/src/code/src/Appwrite/Platform/Tasks/Migrate.php(98): Utopia\Registry\Registry->get('db', true)#3 /usr/src/code/src/Appwrite/Platform/Tasks/Migrate.php(34): Appwrite\Platform\Tasks\Migrate->action('1.5.4', Object(Utopia\Cache\Cache), Object(Utopia\Database\Database), Object(Closure), Object(Utopia\Registry\Registry))#4 /usr/src/code/vendor/utopia-php/cli/src/CLI/CLI.php(320): Appwrite\Platform\Tasks\Migrate->Appwrite\Platform\Tasks\{closure}('1.5.4', Object(Utopia\Cache\Cache), Object(Utopia\Database\Database), Object(Closure), Object(Utopia\Registry\Registry))#5 /usr/src/code/app/cli.php(191): Utopia\CLI\CLI->run()#6 {main} thrown in /usr/src/code/app/init.php on line 928Rank 1: Thread
In case anything in that stack trace is of any use
you should have called this from one of the existing test appwrite containers. is that what you did?
also you should update to 1.5.7
Rank 1: Thread
oh, right, let me flip this back to 1.5.7, I was hitting 1.5.4 because 1.5.7 didnt work. I thought maybe I needed to step version by version
Rank 1: Thread
I called migrate AFTER starting the test container using 1.5.7
Should the running container be 1.4.14 but I run migrate with the 1.5.7 app/src ?
running container should be 1.5.7
Rank 1: Thread
That was the case, but let me go back to 1.5.7 and validate
something seems wrong with your db connection
inspec the container and make sure the _APP_DB_* env vars are correct and the user has full access to the db
Rank 1: Thread
Do you know if there is some command/file in the appwrite container that I could use to validate the sql connection from within the container? I assume mysql client is not there. But thought there might be an appwrite based php or node command I could run to validate DB connection
maybe the doctor command: https://appwrite.io/docs/advanced/self-hosting/debug#doctor-cli
but that might give the same error
Rank 1: Thread
I'll give it a shot
Rank 1: Thread
Does the main appwrite container use: _APP_OPENSSL_KEY_V1 now?
it always did 👀
Rank 1: Thread
once this is up, I'll try that as well. I didn't have that set on 1.4.x for the main appwrite container...
Rank 1: Thread
I bet it was pulling the default secret key and working for that reason
Rank 1: Thread
Rank 1: Thread
Doctor seems to be able to connect to the db
Rank 1: Thread
both console and Projects
👀 there isn't a default
this is the same container you ran the migrate command?
Rank 1: Thread
yes