Problems running on startup a service created in a postinstall script in 12.3

Rainer Krienke <[email protected]>
Newsgroups gmane.linux.suse.autoinstall
Message-ID <[email protected]>
Hello,

to automatically install a openSuSE 12.3 desktop client that fits into
our network environment I need to change several configs uopn
installtion so little manual postinstallation is needed afterwards. I do
this using an autoyast installation that includes a postinstall script.
This used to work fine until systemd came up.

In openSuSE 12.3 I create a service file
/lib/systemd/system/lfinalinstall that looks like this:
------------------
[Unit]
Description=lfinalinstall install script
After=apparmor.service local-fs.target network.service
Before=xdm.service

[Service]
Type=oneshot
Environment=SYSTEMD_NO_WRAP=1 TERM=linux
ExecStart=$LSCRIPT
RemainAfterExit=yes
TimeoutSec=0
StandardInput=tty

[Install]
WantedBy=default.target
-----------------

Next I run  "/bin/systemctl enable lfinalinstall" and finally I run
"systemctl daemon-reload"

After the postinstall scripts of autoyast have been executed my script
lfinalinstall  is actually beeing started. The problem is that it
depends on a running network, but the interface eth0 is still
unconfigured (no dhcpcd is running for it yet, no ip assigned) at this
time and so my script cannot do the job its supposed to do and fails.
After a manual reboot thisngs work.

Does anyone have an idea what I have to do to have the finalinstall
service started when network is available? The dependency on
network.service seems not to work for me.

Thanks
Rainer Krineke
-- 
Rainer Krienke, Uni Koblenz, Rechenzentrum, A22, Universitaetsstrasse  1
56070 Koblenz, http://userpages.uni-koblenz.de/~krienke, Tel: +49261287 1312
PGP: http://userpages.uni-koblenz.de/~krienke/mypgp.html,Fax: +49261287
1001312
smime.p7s (application/pkcs7-signature, 4.6 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.