Re: opensmtpd faq commands

2017-01-30 Thread Gilles Chehade
On Mon, Jan 30, 2017 at 07:00:18PM -0500, Daniel Jakots wrote:
> On Mon, 30 Jan 2017 18:38:12 -0500, Daniel Jakots 
> wrote:
> 
> > Hi,
> > 
> > When following the example from the OpenSMTPD faq [0], first thing is
> > to create a new user with:
> > 
> > useradd -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin vmail
> > 
> > which raises
> >   warnx("Warning: home directory `%s' doesn't exist, and -m was"
> >   " not specified", home);
> > 
> > I don't think giving a command that produces a warning is a good thing
> > in an official documentation. Also solving this problem make other
> > commands useless so it's a bit shorter.
> > 
> > [0]: https://opensmtpd.org/faq/example1.html
> 
> While checking that my diff wasn't mangled, I noticed that it doesn't
> follow html syntax from OpenBSD faq, so let's be consistent:
> 

ok


> Index: opensmtpd/faq/example1.html
> ===
> RCS file: /cvs/www/opensmtpd/faq/example1.html,v
> retrieving revision 1.12
> diff -u -p -r1.12 example1.html
> --- opensmtpd/faq/example1.html   31 Oct 2016 20:52:22 -  1.12
> +++ opensmtpd/faq/example1.html   30 Jan 2017 23:58:39 -
> @@ -90,9 +90,7 @@ virtual users.
>  This user needs to be created:
>  
>  
> -# useradd -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin 
> vmail
> -# mkdir /var/vmail
> -# chown vmail:vmail /var/vmail
> +# useradd -m -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin 
> vmail
>  
>  
>  Afterwards, the /etc/passwd file will contain an entry like
> @@ -199,9 +197,9 @@ maildir folder are mapped to the single 
>  In this example, Dovecot is used as an IMAP server.
>  
>  
> -# export 
> PKG_PATH=http://your.local.mirror/pub/OpenBSD/%c/packages/%a
> -# pkg_add dovecot
> -# rcctl enable dovecot
> +# export PKG_PATH=http://your.local.mirror/pub/OpenBSD/%c/packages/%a
> +# pkg_add dovecot
> +# rcctl enable dovecot
>  
>  
>  Virtual users access and read their mails via IMAP.
> 

-- 
Gilles Chehade

https://www.poolp.org  @poolpOrg



Re: opensmtpd faq commands

2017-01-30 Thread Daniel Jakots
On Mon, 30 Jan 2017 18:38:12 -0500, Daniel Jakots 
wrote:

> Hi,
> 
> When following the example from the OpenSMTPD faq [0], first thing is
> to create a new user with:
> 
> useradd -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin vmail
> 
> which raises
>   warnx("Warning: home directory `%s' doesn't exist, and -m was"
>   " not specified", home);
> 
> I don't think giving a command that produces a warning is a good thing
> in an official documentation. Also solving this problem make other
> commands useless so it's a bit shorter.
> 
> [0]: https://opensmtpd.org/faq/example1.html

While checking that my diff wasn't mangled, I noticed that it doesn't
follow html syntax from OpenBSD faq, so let's be consistent:

Index: opensmtpd/faq/example1.html
===
RCS file: /cvs/www/opensmtpd/faq/example1.html,v
retrieving revision 1.12
diff -u -p -r1.12 example1.html
--- opensmtpd/faq/example1.html 31 Oct 2016 20:52:22 -  1.12
+++ opensmtpd/faq/example1.html 30 Jan 2017 23:58:39 -
@@ -90,9 +90,7 @@ virtual users.
 This user needs to be created:
 
 
-# useradd -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin 
vmail
-# mkdir /var/vmail
-# chown vmail:vmail /var/vmail
+# useradd -m -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin 
vmail
 
 
 Afterwards, the /etc/passwd file will contain an entry like
@@ -199,9 +197,9 @@ maildir folder are mapped to the single 
 In this example, Dovecot is used as an IMAP server.
 
 
-# export 
PKG_PATH=http://your.local.mirror/pub/OpenBSD/%c/packages/%a
-# pkg_add dovecot
-# rcctl enable dovecot
+# export PKG_PATH=http://your.local.mirror/pub/OpenBSD/%c/packages/%a
+# pkg_add dovecot
+# rcctl enable dovecot
 
 
 Virtual users access and read their mails via IMAP.



opensmtpd faq commands

2017-01-30 Thread Daniel Jakots
Hi,

When following the example from the OpenSMTPD faq [0], first thing is to
create a new user with:

useradd -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin vmail

which raises
  warnx("Warning: home directory `%s' doesn't exist, and -m was"
  " not specified", home);

I don't think giving a command that produces a warning is a good thing
in an official documentation. Also solving this problem make other
commands useless so it's a bit shorter.

[0]: https://opensmtpd.org/faq/example1.html

Cheers,
Daniel

Index: opensmtpd/faq/example1.html
===
RCS file: /cvs/www/opensmtpd/faq/example1.html,v
retrieving revision 1.12
diff -u -p -r1.12 example1.html
--- opensmtpd/faq/example1.html 31 Oct 2016 20:52:22 -  1.12
+++ opensmtpd/faq/example1.html 30 Jan 2017 23:35:54 -
@@ -90,9 +90,7 @@ virtual users.
 This user needs to be created:
 
 
-# useradd -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin 
vmail
-# mkdir /var/vmail
-# chown vmail:vmail /var/vmail
+# useradd -m -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin 
vmail
 
 
 Afterwards, the /etc/passwd file will contain an entry like