Koozali.org: home of the SME Server
Obsolete Releases => SME 7.x Contribs => Topic started by: gordonr on January 08, 2007, 12:48:36 PM
-
[Repost from devinfo list]
[unsticky, linked from manual http://smeserver.sourceforge.net/sme7/tech/Chapter6#h1098-4]
Contrib developers, in particular, please remember:
RPMs should not install templates in /etc/e-smith/templates-custom or templates-user-custom
Why not? Take this situation:
- User installs RPM which contains custom template
- User performs backup (which backs up custom templates, as it should)
- User restores backup on another machine (without the RPM installed)
- Custom template is restored, but the rest of the features from the RPM are not
- In the case of email, this could mean lost mail
Now take this one:
- User performs backup
- User upgrades various packages, including the RPMs with custom-templates
- User performs a restore, thinking they just restored user data
- Old custom template fragment causes pain
Custom templates are for the local sysadmin's use - to override behaviour on this system. RPMs should install fragments in /etc/e-smith/templates or /etc/e-smith/templates-user
In almost all cases you can add a new template fragment instead of overriding a standard fragment.
If you can't, then please RAISE A BUG and discuss what you want to change, why you want to make the change and how you suggest changing it.
Please read the dev guide for details. It can be found at:
http://wiki.contribs.org/development
Thanks,
Gordon
-
Just some additional info that may be helpful & to make it clear...
-backup/restore doesn't restore the templates dir.
-to quickly see your custom changes in the templates dir run: /sbin/e-smith/audittools/templates
-
Just some additional info that may be helpful & to make it clear...
backup doesn't backup the templates dir.
As far as I remember it does, if not you should file a bug report.
-
Just some additional info that may be helpful & to make it clear...
backup doesn't backup the templates dir.
As far as I remember it does, if not you should file a bug report.
Actually, kruhm is correct, at least in the effect of a backup/restore. And you are technically correct that they are backed up (to tape).
The /etc/e-smith/templates and /etc/e-smith/templates-user directories are not restored when performing a restore and this is by design. The templates-custom and templates-user-custom directories are restored.
A tape backup backs up the entire system but only restores system configuration and user data. The standard templates directories are installed from RPMs, and thus do not need to, and should not, be restored.
In order to save space, a desktop backup only backs up system configuration and user data.
Both methods use the same list of files/directories to restore. The desktop backup also uses this list as the list of files/directories to backup.