Run mysql inside roudcube container

Hello,

I completed the migration from NS7, but Roundcube/Webmail was not an option (possibly I was running different version).

I already exported the database from NS7 and uploaded it to NS8, chowned to roundcubemail1:roundcubemail1.

But I cannot figure out how to call mysql command inside the container (especially as it is mariadb). I am a noob for containers, for sure.

First try was the following, with many others later…
runagent -m roundcubemail1 mysql roundcubemail < /home/roundcubemail1/.local/share/containers/storage/volumes/html/_data/roundcubemail.db -u roundcubemail -p

The error is usually:

Traceback (most recent call last):
  File "/usr/local/bin/runagent", line 112, in <module>
    os.execvp(args.COMMAND, [args.COMMAND] + args.ARGS)
  File "<frozen os>", line 574, in execvp
  File "<frozen os>", line 616, in _execvpe
  File "<frozen os>", line 607, in _execvpe
FileNotFoundError: [Errno 2] No such file or directory

Which is I believe due to not finding the mysql command.

I guess I am not far from getting it working, but I cannot get it done.

How could I run mysql command inside roudcube1?

Thank you for your help in advance!

probably you ran the roundcubemail next that was on nethforge if I recall well, this version cannot migrate

2 Likes

To import a database to the containers mariadb:

runagent -m roundcubemail1 podman exec -i mariadb-app mysql roundcubemail < sqldump.sql
2 Likes