Mysql database killed after upgrades

Hi,
I’ve been through a couple of corteza upgrades on my local docker setup. Everytime I do this the database is gone and I have to start from scratch.

I’m using these instructions for setup.
https://docs.cortezaproject.org/corteza-docs/2021.9/devops-guide/offline-deployment/multi-mysql.html

I also noticed that I don’t see my namespace in the database if I look at it with Sequel Pro. Am I somehow using Sqlite?

Hi! I’m a bit confused by this message. DB disappearing is a known issue with SQLite, but never with other db types.

Do you get any errors? If you inspect the logs from the server, what is the DB Corteza is connecting to (should be logged in the beginning)?

Hi Thanks,
I’ll have a look at what the logs say. I’m almost positive it’s not actually using MySQL for some reason. It’s my understanding when using Sqllite you also cannot change module field type which is an issue I’m also having. I’ll report back.

Oops, I guess I am doing things wrong. When doing an upgrade I do the following:
docker-compose down
docker-compose pull
docker-compose up -d

The “Pull” pulls a fresh copy of the database which is why things are disappearing. I don’t understand how to correctly upgrade an instance without killing everything.

“docker-compose up -d” is enough;

Docker compose detects if any of the changes in your configuration (and .env) files are changed and recreates the containers. If config is the same services are NOT restarted. So you can run it 2 or 3 times and it will restart it only once. Try it :slight_smile: