Comments (7)
@davidbeijer If you don't mount the DB into a persistent store somewhere then it will not survive restarts.
I'd suggest using the docker compose method. This will start a mysql DB alongside the kimai app. The data from that mysql instance will be in ./mysql
from kimai2.
@tobybatch first of all thanks for quick response! I've found the yml file for the docker compose method. Despite that option missing from the kimai documentation (I would volunteer to add that once I understand it) I have figured out how to launch the app as described here: https://docs.docker.com/get-started/part3/. While it is running and claiming that the ports are exposed, those ports do not show up if I nmap the host and I can not connect to the app.
I am unsure if this is a problem with the .yml file, googling on topics related to "docker app ports not opening up" and similar did result in usable results for me.
from kimai2.
@davidbeijer Can supply the command you are using to start the container please?
Have you looked at this page?
https://github.com/tobybatch/kimai2/blob/master/prod/README.md
from kimai2.
@tobybatch, yes I saw the README.md for prod. I can run it, it comes up, the port shows up if I nmap the host, however the datastorage is not persistent, and hence me going for the compose-approach.
The commands I run are (assuming a clean install, a clean pull from the github repository, and ip address using the public IP address of the host machine):
docker swarm init --advertise-addr xx.xx.xx.xx:8080
docker stack deploy -c docker-compose.yml kimai2
After that, "docker service ls" returns:
ID NAME MODE REPLICAS IMAGE PORTS
tdcs0nrsgwdi kimai2_kimai replicated 0/1 kimai/kimai2:prod *:8080->8080/tcp
4te16zutqnqe kimai2_mydb replicated 0/1 mysql:5.6
however nmap does not show an open port at 8080 (both when nmap from the host machine to localhost as from my PC towards the server).
from kimai2.
@davidbeijer Thanks you've found a bug in the doc's :(
The port number in the docs should have been 8001 not 8080. Please try to move to that port and restart the containers.
from kimai2.
Hi Toby,
Thanks for the support! I donated to the project via Kevin, couldn't find you specifically on the Kimai2 website.
I got it running today with a persistent database. One problem was the ports as set in the docs, on the other hand my method of bringing the compose entity up did not expose the ports to the outside world. Using "docker-compose up" however did work. I'll write that off to me being relatively new with docker. Could be useful to add to the documentation to avoid other newbies run into this.
One feature suggestion I would have would be the ability to disable the "register new user" link as soon as the first user has registered, or having a tick option somewhere in the configuration window. That would greatly increase the security of the app, without the owner having to manage with configuration files.
from kimai2.
Hi David, first of all: thanks!
Now we are mixing docker and non-docker issues, but well ... here we go:
Some configs are so deeply integrated, that having them on the UI would introduce a couple of problems from a development perspective.
Also: I would have to spent a lot of time into things which don't bring any benefit to the actually time-tracking - that's why I decided that everyone can simply create a local.yaml and configure the stuff he needs once.
There were a lot of discussion about the "Register new user" link, but to summarize it: even though it is possible to create your first user via command line, it is not possible for the folks who do not have a bash (👎 for shared hosting, but that is still the case for many people out there).
So having that link activated by default is the only option to allow these users to create their first account.
Yes its contrary to "security by default" and maybe I can change it later on, when there is an installer and different packages existing. But for now, please create your local.yaml config: https://github.com/kevinpapst/kimai2/blob/master/var/docs/configurations.md#security
Maybe its an idea to have a separate docu chapter about "first time configurations" or some sample local.yaml to provide help with the first steps.
from kimai2.
Related Issues (20)
- [BUG]Environmemt mailer not function HOT 1
- [Documentation] ReadMe on DockerHub contains faulty (legacy?) information on user creation HOT 1
- [BUG] Undefined constant Symfony\Component\HttpFoundation\Request::HEADER_X_FORWARDED_ALL HOT 1
- [BUG] Failed to validate database. Invalid platform version. HOT 15
- [BUG] Error 500 at Plugins after Upgrading HOT 1
- [BUG] Error 500 at plugins HOT 3
- [BUG] Doctrine DBAL - Invalid platform version HOT 1
- [BUG] DATABASE URL inconsistencies HOT 2
- Issue with "Easybackup" Plugin in Kimai Docker Environment HOT 4
- Kimai with Traefik as reverse proxy redirects to http when only https is set-up in docker-compose.yml HOT 4
- Problem with kimai:import:v1 - SQLSTATE[HY000] [2002] Connection refused .. HOT 1
- Unable to bind/mount mysql volume and start kimai dokcer HOT 1
- [BUG] Error submitting form according to language HOT 2
- Kimai with ProxyRevers: Menu-Buttons in Kimai Version 2.2.1 do not work HOT 1
- missing swagger.json HOT 2
- AD authentication fails if the user object has a child object (ActiveSyncDevice) HOT 1
- [BUG] copy-public.sh: Where is it? HOT 5
- [BUG] Setting memory limit permission issue HOT 5
- [BUG] 500 Error - Missing class in latest docker image (2.5.0) HOT 3
- [BUG] composer require symfony/sendgrid-mailer fails HOT 9
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kimai2.