Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Florian Lindner
Lennart Poettering wrote: > On Wed, 20.08.14 10:25, Florian Lindner (mailingli...@xgm.de) wrote: > >> The timer I try to enable contains a Install section. >> >> florian@asaru ~/.config/systemd/user % cat git-commit@.timer >> [Unit] >> Description=Timer to commit all changes in instance. >> >>

Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Lennart Poettering
On Wed, 20.08.14 10:25, Florian Lindner (mailingli...@xgm.de) wrote: > The timer I try to enable contains a Install section. > > florian@asaru ~/.config/systemd/user % cat git-commit@.timer > [Unit] > Description=Timer to commit all changes in instance. > > [Timer] > OnUnitActiveSec=5min > OnAct

Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Lennart Poettering
On Wed, 20.08.14 06:21, Andrei Borzenkov (arvidj...@gmail.com) wrote: > > В Tue, 19 Aug 2014 22:54:04 +0200 > Lennart Poettering пишет: > > > On Tue, 19.08.14 19:34, Florian Lindner (mailingli...@xgm.de) wrote: > > > > > Hello, > > > I have a systemd unit that should do a commit on a specific

Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Florian Lindner
Anthony Messina wrote: > On Wednesday, August 20, 2014 10:25:35 AM Florian Lindner wrote: >> [Timer] >> OnUnitActiveSec=5min >> OnActiveSec=5min >> AccuracySec = 5min > > I'm not sure it matters, but you have some extra spaces around "=" after > AccuracySec. No, that shouldn't be the problem, I

Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Anthony Messina
On Wednesday, August 20, 2014 10:25:35 AM Florian Lindner wrote: > [Timer] > OnUnitActiveSec=5min > OnActiveSec=5min > AccuracySec = 5min I'm not sure it matters, but you have some extra spaces around "=" after AccuracySec. -- Anthony - https://messinet.com/ - https://messinet.com/~amessina/gal

Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Florian Lindner
Florian Lindner wrote: > Andrei Borzenkov wrote: > >> В Tue, 19 Aug 2014 22:08:26 +0200 >> Florian Lindner пишет: >> >>> Andrei Borzenkov wrote: >>> >>> > В Tue, 19 Aug 2014 20:59:55 +0200 >>> > Florian Lindner пишет: >>> > >>> >> >>> >> I also try to set up a matching timer: >>> >> >>> >>

Re: [systemd-devel] Using path name in instantiated units

2014-08-20 Thread Florian Lindner
Andrei Borzenkov wrote: > В Tue, 19 Aug 2014 22:08:26 +0200 > Florian Lindner пишет: > >> Andrei Borzenkov wrote: >> >> > В Tue, 19 Aug 2014 20:59:55 +0200 >> > Florian Lindner пишет: >> > >> >> >> >> I also try to set up a matching timer: >> >> >> >> systemctl --user start git-commit@/home

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Andrei Borzenkov
В Tue, 19 Aug 2014 22:08:26 +0200 Florian Lindner пишет: > Andrei Borzenkov wrote: > > > В Tue, 19 Aug 2014 20:59:55 +0200 > > Florian Lindner пишет: > > > >> > >> I also try to set up a matching timer: > >> > >> systemctl --user start git-commit@/home/florian/timer.test.timer > >> > >> wor

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Andrei Borzenkov
В Tue, 19 Aug 2014 22:54:04 +0200 Lennart Poettering пишет: > On Tue, 19.08.14 19:34, Florian Lindner (mailingli...@xgm.de) wrote: > > > Hello, > > I have a systemd unit that should do a commit on a specific path. Since > > there are more then one path / repos, I want to use an instantiated uni

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Lennart Poettering
On Tue, 19.08.14 19:34, Florian Lindner (mailingli...@xgm.de) wrote: > Hello, > I have a systemd unit that should do a commit on a specific path. Since > there are more then one path / repos, I want to use an instantiated unit for > that (the stuff with @ in the unit name): > > > ~/.config/sys

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Anthony Messina
On Tuesday, August 19, 2014 07:34:46 PM Florian Lindner wrote: > Any ideas how I can change the working directory to the directory given by > the instance name? I do something like this to rebuild Jekyll sites based on a git commit. Maybe this will help you. 1. A path unit watches for changes t

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Florian Lindner
Andrei Borzenkov wrote: > В Tue, 19 Aug 2014 20:59:55 +0200 > Florian Lindner пишет: > >> >> I also try to set up a matching timer: >> >> systemctl --user start git-commit@/home/florian/timer.test.timer >> >> works fine, but: >> >> systemctl --user enable git-commit@/home/florian/timer.test.

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Andrei Borzenkov
В Tue, 19 Aug 2014 20:59:55 +0200 Florian Lindner пишет: > > I also try to set up a matching timer: > > systemctl --user start git-commit@/home/florian/timer.test.timer > > works fine, but: > > systemctl --user enable git-commit@/home/florian/timer.test.timer > Failed to execute operation: In

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Florian Lindner
Andrei Borzenkov wrote: > В Tue, 19 Aug 2014 19:34:46 +0200 > Florian Lindner пишет: > >> >> It seems that using %i or %I to set the working directory does not work. > > bor@opensuse:~> sudo systemctl start foo@/home/bor.service > bor@opensuse:~> cat /tmp/foo > /home/bor > %i=-home-bor > %I=/h

Re: [systemd-devel] Using path name in instantiated units

2014-08-19 Thread Andrei Borzenkov
В Tue, 19 Aug 2014 19:34:46 +0200 Florian Lindner пишет: > > It seems that using %i or %I to set the working directory does not work. bor@opensuse:~> sudo systemctl start foo@/home/bor.service bor@opensuse:~> cat /tmp/foo /home/bor %i=-home-bor %I=/home/bor bor@opensuse:~> cat /run/systemd/sys

[systemd-devel] Using path name in instantiated units

2014-08-19 Thread Florian Lindner
Hello, I have a systemd unit that should do a commit on a specific path. Since there are more then one path / repos, I want to use an instantiated unit for that (the stuff with @ in the unit name): ~/.config/systemd/user % cat git-commit@.service [Unit] Description=Auto commit for instance. [S