[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Example: distributing a file created from two templates without NFS.
From: |
Hugo Gayosso |
Subject: |
Example: distributing a file created from two templates without NFS. |
Date: |
11 Dec 2001 10:26:52 +0500 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.1 |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Problem description
===================
All the servers should contain a set of aliases for system accounts,
all of them should be the same. (aliases.system)
One of the servers (for example) should contain the above mentioned
set plus a set of mailing list aliases (aliases.mailinglists).
I don't want to have NFS dependencies between hosts for different
reasons (some of them might not even have NFS installed). Therefore
using "editfiles -> InsertFile" is not an option.
Solution (if you have a better one, PLEASE tell me)
========
aliases.system is distributed using "copy".
The master files server creates a new file
(aliases.mailinglistserver) using cfengine and this file is
distributed via "copy".
We can use "editfiles -> InsertFile" in the master file server
because everything is local.
###############################################################################
#
# cf.aliases
#
###############################################################################
copy:
!MailinglistServers::
$(masterfiles)/mail/aliases.system dest=/etc/aliases
mode=444 owner=root group=root
type=checksum action=fix
define=restartALIASES
secure=true
server=$(masterfiles_server)
MailinglistServers::
$(masterfiles)/mail/aliases.mailinglistserver dest=/etc/aliases
mode=444 owner=root
group=root
type=checksum action=fix
define=restartALIASES
secure=true
server=$(masterfiles_server)
editfiles:
MasterfilesServers::
{ $(masterfiles)/mail/aliases.mailinglistserver
AutoCreate
EmptyEntireFilePlease
InsertFile "$(masterfiles)/mail/aliases.system"
InsertFile "$(masterfiles)/mail/aliases.mailinglists"
}
shellcommands:
restartALIASES::
"/usr/bin/newaliases"
- --
Hugo Gayosso
Support the Free Software Movement!
GNU Project <http://www.gnu.org>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
iD8DBQE8FZkcx2JZtTN6co8RAjTpAKC3w+okjfRwYWOKih/gMBcPp+RThwCg+LyZ
M6o14Q9ONXvpTsaJJHjAa34=
=w0d8
-----END PGP SIGNATURE-----
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Example: distributing a file created from two templates without NFS.,
Hugo Gayosso <=