Closed axel1202 closed 1 year ago
Looks like a problem of EasyBackupBundle to me, maybe it is just not docker compatible. I don't see anything that is docker related. Maybe the unknown database issues, but then: if Kimai works and the bundle doesn't...
Looks like a problem of EasyBackupBundle to me, maybe it is just not docker compatible. I don't see anything that is docker related. Maybe the unknown database issues, but then: if Kimai works and the bundle doesn't...
yeah - obviously the kimai contaienr itself has no problem connecting to the mysql container, the given database connect string user@pass@mysql/kimai should be correct as well... so, I dont get it :-) maybe the EasyBackup-Dev gets note of this post here...
Thanks fpr the quick reply anyways
We can give him a ping @mxgross - do you have any idea?
Hi, unfortunately I cannot have a deeper look at it currently. I did not yet test it in docker but I can imagine that there are a few problems in my bundle regarding docker. I will put this in my reminder and hope I can start analyzing it next weekend.
We can give him a ping @mxgross - do you have any idea?
He already replied :-) in a way... ;-)
Hi, unfortunately I cannot have a deeper look at it currently. I did not yet test it in docker but I can imagine that there are a few problems in my bundle regarding docker. I will put this in my reminder and hope I can start analyzing it next weekend.
That'd be nice - no hurry... Would be nice, if we could run that dockerized at some time :-)
I will take a look at this when I get a chance, but the containerised applications are running in their own little network, where sqldb should resolve to the DB host.
I can't easily see why it wouldn't work
Can you add
ports:
- 3036:3036
to the db container and see if you can connect to it directly?
Can you add
ports: - 3036:3036
to the db container and see if you can connect to it directly?
Works a treat from outside...
-- as well as from inside the kimai container:
:-)
So I think the issue in the plugin. I'm going to convert this into a discussion rather than an issue with the kimai container.
Describe the bug I am not sure, where to address this issue - either kaimai:apache or EasyBackup plugin.
When setting up kimai in Docker with 2 containers for the mysql-db and kimai:apache, EasyBackup complains, that it can't find the mysql and mysqldump commands / tools.
So I derived a new image from kimai:apache, where I additionally installed said tools. I did that the lazy way - logged into the running container, installed mysql client tools and then just creted a new image of that container (localimages/kimai) and restarted everything using this new image - obviously works hunky-dory, because then the plugin status showed OK:
Despite of that seemingly good status running a restore then throws a huge amount of warnings and errors (see below), among others stating, that the specified db is unknown:
[2023-01-08 17:55:12] ERROR: ERROR 2005 (HY000): Unknown MySQL server host 'sqldb/kimai' (-2)
This is especially confusing, as the status check (see screenshot above) marks the database as OK...
This seems to be the main problem.
Furthermore there are a lot of access permission errors, some of which referr to directories NOT related to volumes mounted from outside:
[2023-01-08 17:55:12] ERROR: Failed to change permissions of '/opt/kimai/config/packages/local.yaml' to '511'.
and mainly referring to file permissions within the mounted volumes:
[2023-01-08 17:55:12] INFO: '/opt/kimai/var/plugins/EasyBackupBundle/.php_cs.dist' is not writable. [2023-01-08 17:55:12] ERROR: Failed to change permissions of '/opt/kimai/var/plugins/.gitkeep' to '511'.
this certainly might be solvable by setting the proper permissions, but I am not sure what those would look like.
To Reproduce Steps to reproduce the behaviour:
Desktop (please complete the following information):
Command used to run the container
Docker compose file (with passwords redacted) (portainer stack definition)
directory structure of mounted volumes as seen from the volumes' host
the log from EasyBackup