I am attempting to move my docker-compose installation from one server to another.
I stopped the docker containers on the source server.
I exactly reproduced the source server directory on the destination server (using rsync).
I started the docker containers on the destination server.
Problem 1: The containers could not connect to the database.
Solution 1: I went into the database container and GRANTed permission. Can’t see why I had to do that?
Problem 2: When I login, and go to the Desk, I get an error
pymysql.err.OperationalError: (1054, "Unknown column 'onboarding_status' in 'field list'")
More Info: I went into the frontend container and searched for that string. It was all over the place. But in the original container, it was not found at all.
I can only assume that building the containers on the new server has built a different version, but not bothered to update the database schema.
I tried deleting the entire contents of the app directory in every container, and restoring them from the containers in the original server. But, every time I restart the containers, they come back.
How do I make this work?
How is the database supposed to be updated to contain the fields expected in the latest code? Is this not automatic?