Do you plan to make a CLI?

Asked by Boyard Nicolas

Hello,
As stated in the summary I was wondering if you planned to make a command-line interface in order to administrate the application from distance with SSH, or is there already configuration files we can edit by hand? All I've found online are articles using the GUI.

Question information

Language:
English Edit question
Status:
Solved
For:
timekpr-revived Edit question
Assignee:
No assignee Edit question
Solved by:
Eduards Bezverhijs
Solved:
Last query:
Last reply:
Revision history for this message
Best Eduards Bezverhijs (mjasnik) said :
#1

Hi,

no CLI is planned at this time, surely not in this version at least.

These config files will help you (substitute user for Your actual user):
/var/lib/timekpr/user.time - this lists the time available for particular user, starts from 0 to available seconds till the allowed time either to the end of the day or to the limit assigned to user, DO NOT enter more than max seconds per day, DO NOT enter decimals, etc.
/etc/security/time.conf - this file contains access time limits for user, please DO NOT enter fancy configuration, timekpr expects very simple config as You'll see in there
/etc/timekpr/user - this file contains limits per day per particular user, simple

If ANY config is not understandable by timekpr, it won't function properly (change with caution !!!).

BR, Eduards

Revision history for this message
Boyard Nicolas (boboyy) said :
#2

Hi,
Actually I've installed the software from distance so users are not configured right now, I don't see a user file generated yet.
I guess I'll have to wait until I get my hands on the computer.
As for /etc/security/time.conf I'm already using it with : login ; * ; crapaud ; Al0900-2000 is it simple enough?
Though I had a problem with it, the user was logged out at 8pm as expected but he was able to log-in after, caught him using the computer at 11pm, could it be because the user was in the nopasswdlogin group then no checks were made upon login?

Anyway thank you for your time.
BR, Nicolas

Revision history for this message
Boyard Nicolas (boboyy) said :
#3

Thanks Eduards Bezverhijs, that solved my question.

Revision history for this message
Eduards Bezverhijs (mjasnik) said :
#4

Sample files (from one of the working installs)

---=== /var/lib/timekpr/user.time (file as is) ===---
1200
---======---

---=== /etc/security/time.conf (TIMEKPR section at the end of file) ===---
## TIMEKPR START
*;*;user;Su0800-2400 | Mo0800-2400 | Tu0800-2400 | We0800-2400 | Th0800-2400 | Fr0800-2400 | Sa0800-2400
## TIMEKPR END
---======---

---=== /etc/timekpr/user(file as is) ===---
limit=( 14400 14400 14400 14400 14400 14400 14400 )
---======---

Revision history for this message
Boyard Nicolas (boboyy) said :
#5

---=== /var/lib/timekpr/user.time (file as is) ===---
1200 (is it the remaining time for the day? 20 minutes?)

The user is allowed to use the session for 14400 seconds (4 hours) every day and the user.time file is updated like every minute to decrement user.time file? Then user.time is reset everyday from user file. Is that so?
If that's it then I guess I have all I need to configure it properly.
Thank you Eduards.

Revision history for this message
Eduards Bezverhijs (mjasnik) said :
#6

1200 is the time already spent, it goes up to the limit, which in my case is 14400.
So every day this gets reset to 0 and updated every 30 secs by default.