Author: baggins                      Date: Sun Jan 29 09:33:05 2012 GMT
Module: packages                      Tag: HEAD
---- Log message:
- setup hostname from /etc/sysconfig/network on first install

---- Files affected:
packages/systemd:
   systemd.spec (1.95 -> 1.96) 

---- Diffs:

================================================================
Index: packages/systemd/systemd.spec
diff -u packages/systemd/systemd.spec:1.95 packages/systemd/systemd.spec:1.96
--- packages/systemd/systemd.spec:1.95  Sun Jan 29 09:39:56 2012
+++ packages/systemd/systemd.spec       Sun Jan 29 10:32:59 2012
@@ -310,6 +310,14 @@
 
        # And symlink what we found to the new-style default.target
        ln -s "$target" %{_sysconfdir}/systemd/system/default.target >/dev/null 
2>&1 || :
+
+       # Setup hostname
+       [ -f /etc/sysconfig/network ] && . /etc/sysconfig/network
+       if [ -n "$HOSTNAME" -a "$HOSTNAME" != "pldmachine" ]; then
+               [ -f /etc/hostname ] && mv -f /etc/hostname 
/etc/hostname.rpmsave
+               echo $HOSTNAME > /etc/hostname
+               chmod 644 /etc/hostname
+       fi
 fi
 # Enable the services we install by default.
 /bin/systemctl enable \
@@ -564,6 +572,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.96  2012/01/29 09:32:59  baggins
+- setup hostname from /etc/sysconfig/network on first install
+
 Revision 1.95  2012/01/29 08:39:56  arekm
 - add S: nss_myhostname (suggested by systemd-hostnamed.service)
 
================================================================

---- CVS-web:
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/systemd/systemd.spec?r1=1.95&r2=1.96&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to