katunch
katunch
NNovu
Created by katunch on 3/14/2024 in #💬│support
data migrations according to instructions don't work
Hi everyone ✌️ I've been running a novu self hostet instance using docker-compose for a while now. the running version is v0.9. There are about 16k subscribers and a ton of notifications already stored. Now i'd like to upgrade to the newest version v0.24. There's a nice documentation regarding da migrations here: https://docs.novu.co/additional-resources/data-migrations But they fail. Let me quick explain the setup: - I have running a mongodb on my local machine using docker and imported a dump from the current production version. - I have cloned the next branch using git clone [email protected]:novuhq/novu.git - After that i've adjusted the apps/api/src/.env to point the MONGO_URL to my mongodb Now when i run the migration scripts according the documentation i'll get the following error.
npm run migration -- ./migrations/normalize-users-email/normalize-users-email.migration.ts

> @novu/[email protected] migration
> cross-env NODE_ENV=local MIGRATION=true ts-node --transpileOnly ./migrations/normalize-users-email/normalize-users-email.migration.ts

Environment: local
Platform: Docker
Tenant: OS
Selected Log Transport pino-pretty
Migration Normalize Users Email

npm ERR! Lifecycle script `migration` failed with error:
npm ERR! Error: command failed
npm ERR! in workspace: @novu/[email protected]
npm ERR! at location: /Users/katunch/Developments/novu-notification-platform/novu/apps/api
npm run migration -- ./migrations/normalize-users-email/normalize-users-email.migration.ts

> @novu/[email protected] migration
> cross-env NODE_ENV=local MIGRATION=true ts-node --transpileOnly ./migrations/normalize-users-email/normalize-users-email.migration.ts

Environment: local
Platform: Docker
Tenant: OS
Selected Log Transport pino-pretty
Migration Normalize Users Email

npm ERR! Lifecycle script `migration` failed with error:
npm ERR! Error: command failed
npm ERR! in workspace: @novu/[email protected]
npm ERR! at location: /Users/katunch/Developments/novu-notification-platform/novu/apps/api
Running node v18.19.0 Any idea what's the deal to make migrations running?
2 replies