Repository navigation
How to upgrade/migrate from a 7.x local install to a 8.x Docker install? #1561
|
Hi, we were evaluating MediaCMS for our usage and we installed version 7.6 for our testing back then. We used the I wanted to update the version to see what were the latest improvements and if the changes we made would still be relevant. However, starting with version 8, the What (and where) is the data I have to get from the local installation on the Incus container? And what I have to do to make the newly created Docker container use the existing data from the local install? |
Replies: 3 comments
|
Two things to carry across, the database and On the old box, dump the database and tar the media: Use On the new host, clone the repo, since that directory is the compose directory and it gets bind mounted in wholesale as Then bring up only the database first: Restoring before the rest of the stack starts is the part I'd be careful about. The Once the data is in, Worth knowing about the layout before you go looking for it: the database volume is The UI fixes and translation work you did won't come across in any of this, since that's code rather than data. Those need reapplying against 8.x, and given it's a major version I'd check whether they're still needed at all before porting them over. |
|
从仓库当前 Docker 配置看,升级时需要同时保留两类数据:PostgreSQL 数据库和 建议先做一次可恢复备份,再按这个顺序迁移:
不要把 7.x 的 SQLite/本地配置当作完整备份,也不要在已有数据库上手动执行 fixtures loaddata。7.6→8.x 是否支持直接跨版本迁移,还要以 8.x release notes 和维护者确认的升级路径为准;如果项目只支持逐版本升级,应先在副本上完成中间版本迁移。官方 Docker 配置和启动迁移脚本可参考: https://github.com/mediacms-io/mediacms/blob/main/docker-compose.yaml 以及 https://github.com/mediacms-io/mediacms/blob/main/deploy/docker/prestart.sh |
|
Thank you, @ChangkeunJ and @tony403 for the guidance. With that, I was able to get a MediaCMS instance up with the existing data. Unfortunately, it had to be done on a different computer. The upgrade of the existing install failed: the Docker version of MediaCMS seems to not work on ARM64 because there are no ARM64 images for certain components. The steps you provided to import the data worked. However, MediaCMS itself failed to start with I got one of my old desktops and migrated the data to it (the Regarding the bugs and behaviors, I have tested and at least one of the bugs still exists: the download button links the same video for all resolutions, instead of linking per resolution. I'll have to test things further, but it is really late now. I'm very glad it's running again. Again, thank you for the help. The log below is the failed process on the Orange Pi. Not sure how relevant it is. |
Two things to carry across, the database and
media_files, and the order you do them in matters more here than anything else.On the old box, dump the database and tar the media:
Use
pg_dumprather than copying the Postgres data directory across. The compose file runspostgres:17.2-alpine, which is almost certainly a major version or several ahead of whatever install.sh pulled in from the distro packages, and a raw data directory won't start across a major version gap. Dump and restore is the supported route and it doesn't care about the gap at all.On the new host, clone the r…