summaryrefslogtreecommitdiffstats
path: root/zarb-ml/mageia-sysadm/2011-February/002726.html
diff options
context:
space:
mode:
Diffstat (limited to 'zarb-ml/mageia-sysadm/2011-February/002726.html')
-rw-r--r--zarb-ml/mageia-sysadm/2011-February/002726.html156
1 files changed, 156 insertions, 0 deletions
diff --git a/zarb-ml/mageia-sysadm/2011-February/002726.html b/zarb-ml/mageia-sysadm/2011-February/002726.html
new file mode 100644
index 000000000..e7a6149c2
--- /dev/null
+++ b/zarb-ml/mageia-sysadm/2011-February/002726.html
@@ -0,0 +1,156 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
+<HTML>
+ <HEAD>
+ <TITLE> [Mageia-sysadm] [1005] add the user creation by puppet
+ </TITLE>
+ <LINK REL="Index" HREF="index.html" >
+ <LINK REL="made" HREF="mailto:mageia-sysadm%40mageia.org?Subject=Re%3A%20%5BMageia-sysadm%5D%20%5B1005%5D%20add%20the%20user%20creation%20by%20puppet&In-Reply-To=%3C1297437657.21676.130.camel%40akroma.ephaone.org%3E">
+ <META NAME="robots" CONTENT="index,nofollow">
+ <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
+ <LINK REL="Previous" HREF="002725.html">
+ <LINK REL="Next" HREF="002727.html">
+ </HEAD>
+ <BODY BGCOLOR="#ffffff">
+ <H1>[Mageia-sysadm] [1005] add the user creation by puppet</H1>
+ <B>Michael Scherer</B>
+ <A HREF="mailto:mageia-sysadm%40mageia.org?Subject=Re%3A%20%5BMageia-sysadm%5D%20%5B1005%5D%20add%20the%20user%20creation%20by%20puppet&In-Reply-To=%3C1297437657.21676.130.camel%40akroma.ephaone.org%3E"
+ TITLE="[Mageia-sysadm] [1005] add the user creation by puppet">misc at zarb.org
+ </A><BR>
+ <I>Fri Feb 11 16:20:57 CET 2011</I>
+ <P><UL>
+ <LI>Previous message: <A HREF="002725.html">[Mageia-sysadm] [520] left background update (alexn83)
+</A></li>
+ <LI>Next message: <A HREF="002727.html">[Mageia-sysadm] [1004] add a replyto for mail from bot and the user creation by puppet
+</A></li>
+ <LI> <B>Messages sorted by:</B>
+ <a href="date.html#2726">[ date ]</a>
+ <a href="thread.html#2726">[ thread ]</a>
+ <a href="subject.html#2726">[ subject ]</a>
+ <a href="author.html#2726">[ author ]</a>
+ </LI>
+ </UL>
+ <HR>
+<!--beginarticle-->
+<PRE>Le vendredi 11 f&#233;vrier 2011 &#224; 16:11 +0100, <A HREF="https://www.mageia.org/mailman/listinfo/mageia-sysadm">root at mageia.org</A> a &#233;crit :
+&gt;<i> Revision: 1005
+</I>&gt;<i> Author: dams
+</I>&gt;<i> Date: 2011-02-11 16:11:00 +0100 (Fri, 11 Feb 2011)
+</I>&gt;<i> Log Message:
+</I>&gt;<i> -----------
+</I>&gt;<i> add the user creation by puppet
+</I>
+The commit message do not correspond much to what happened
+( ie, there was also others changes ). I do use a specific hook in vim
+to have a diff when redacting the commit message to precisely avoid
+this, see <A HREF="http://www.vim.org/scripts/script.php?script_id=978">http://www.vim.org/scripts/script.php?script_id=978</A> ( yup,
+self promotion )
+
+
+&gt;<i> Modified: puppet/modules/blog/manifests/init.pp
+</I>&gt;<i> ===================================================================
+</I>&gt;<i> --- puppet/modules/blog/manifests/init.pp 2011-02-11 15:10:39 UTC (rev 1004)
+</I>&gt;<i> +++ puppet/modules/blog/manifests/init.pp 2011-02-11 15:11:00 UTC (rev 1005)
+</I>&gt;<i> @@ -1,14 +1,28 @@
+</I>&gt;<i> -#TODO:
+</I>&gt;<i> -# - add the creation of the user 'blog' in puppet
+</I>&gt;<i> -# - add the user 'blog' to the 'apache' group (usermod -a -G apache blog)
+</I>&gt;<i> class blog {
+</I>&gt;<i> + user { &quot;blog&quot;:
+</I>&gt;<i> + groups =&gt; apache,
+</I>&gt;<i> + comment =&gt; &quot;This user is used for blog.mageia.org&quot;,
+</I>
+This comment is not very helpful to explain the use of the user.
+And as I said numerous time, I think we should try to avoid hardcoding
+domain name in puppet. WHile a comment has no incidence, it just add
+noise when someone want to check that nothing is hardcoded ( using
+grep ).
+
+&gt;<i> + ensure =&gt; present,
+</I>&gt;<i> + managehome =&gt; true,
+</I>&gt;<i> + }
+</I>&gt;<i> +
+</I>&gt;<i> include apache::mod_php
+</I>&gt;<i> include mysql
+</I>&gt;<i> + apache::vhost_other_app { &quot;blog-test.$domain&quot;:
+</I>&gt;<i> + vhost_file =&gt; &quot;blog/01_blogs_vhosts.conf&quot;,
+</I>&gt;<i> + }
+</I>
+The name of templates could be IMHO be better.
+
+
+&gt;<i> package { ['wget','php-mysql']:
+</I>&gt;<i> ensure =&gt; installed
+</I>&gt;<i> }
+</I>&gt;<i>
+</I>&gt;<i> + file { &quot;/var/lib/blog&quot;:
+</I>&gt;<i> + ensure =&gt; directory,
+</I>&gt;<i> + owner =&gt; blog,
+</I>&gt;<i> + group =&gt; blog,
+</I>&gt;<i> + mode =&gt; 644,
+</I>&gt;<i> + }
+</I>&gt;<i> +
+</I>&gt;<i> file { &quot;check_new-blog-post&quot;:
+</I>&gt;<i> path =&gt; &quot;/usr/local/bin/check_new-blog-post.sh&quot;,
+</I>&gt;<i> ensure =&gt; present,
+</I>&gt;<i> @@ -18,20 +32,9 @@
+</I>&gt;<i> content =&gt; template(&quot;blog/check_new-blog-post.sh&quot;)
+</I>&gt;<i> }
+</I>&gt;<i>
+</I>&gt;<i> - apache::vhost_other_app { &quot;blog-test.$domain&quot;:
+</I>&gt;<i> - vhost_file =&gt; &quot;blog/01_blogs_vhosts.conf&quot;,
+</I>&gt;<i> - }
+</I>&gt;<i> -
+</I>&gt;<i> - file { &quot;/var/lib/blog&quot;:
+</I>&gt;<i> - ensure =&gt; directory,
+</I>&gt;<i> - owner =&gt; blog,
+</I>&gt;<i> - group =&gt; blog,
+</I>&gt;<i> - mode =&gt; 644,
+</I>&gt;<i> - }
+</I>&gt;<i> -
+</I>&gt;<i> file { &quot;/var/www/html/blog.mageia.org&quot;:
+</I>the naming of the directory is also hardcoded for no good reason.
+
+&gt;<i> ensure =&gt; directory,
+</I>&gt;<i> - owner =&gt; apache,
+</I>&gt;<i> + owner =&gt; blog,
+</I>&gt;<i> group =&gt; blog,
+</I>&gt;<i> mode =&gt; 644,
+</I>&gt;<i> }
+</I>
+
+--
+Michael Scherer
+
+</PRE>
+
+
+
+
+
+
+
+
+
+
+
+
+<!--endarticle-->
+ <HR>
+ <P><UL>
+ <!--threads-->
+ <LI>Previous message: <A HREF="002725.html">[Mageia-sysadm] [520] left background update (alexn83)
+</A></li>
+ <LI>Next message: <A HREF="002727.html">[Mageia-sysadm] [1004] add a replyto for mail from bot and the user creation by puppet
+</A></li>
+ <LI> <B>Messages sorted by:</B>
+ <a href="date.html#2726">[ date ]</a>
+ <a href="thread.html#2726">[ thread ]</a>
+ <a href="subject.html#2726">[ subject ]</a>
+ <a href="author.html#2726">[ author ]</a>
+ </LI>
+ </UL>
+
+<hr>
+<a href="https://www.mageia.org/mailman/listinfo/mageia-sysadm">More information about the Mageia-sysadm
+mailing list</a><br>
+</body></html>