Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Jul 2018 15:54:32 +0200
From:      Mathieu Arnold <mat@FreeBSD.org>
To:        Babak Farrokhi <farrokhi@FreeBSD.org>
Cc:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   Re: svn commit: r474859 - in head/sysutils: . omnibackup omnibackup/files
Message-ID:  <20180718135432.zkwre46ms6fnefeo@ogg.in.absolight.net>
In-Reply-To: <201807181248.w6ICmXKg064609@repo.freebsd.org>
References:  <201807181248.w6ICmXKg064609@repo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--lkntcoddxnhptn4q
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

First off, everything is badly placed, for example, but not limited to,
OPTIONS where the DEPENDS should be.

On Wed, Jul 18, 2018 at 12:48:33PM +0000, Babak Farrokhi wrote:
> +RUN_DEPENDS+=3D	\

Why +=3D ?

> +SUB_FILES=3D	pkg-message
> +SUB_LIST=3D	ROOT_HOME=3D/root

SUB_LIST is for variables, ROOT_HOME is pretty static, no need to use a
placeholder for it.

> +PLIST_FILES=3D	\
> +	bin/omnibackup \
> +	${ETCDIR}/config.json.sample

This should be using @sample.

> +.include <bsd.port.options.mk>
> +
> +.if ${PORT_OPTIONS:MDOCS}
> +PLIST_FILES+=3D	${DOCSDIR}/README.md
> +.endif

All this could be replaced by:

PORTDOCS=3Dreadme.md

> +.if ${PORT_OPTIONS:MOPENLDAP} \
> +	|| ${PORT_OPTIONS:MPGSQL} \
> +	|| ${PORT_OPTIONS:MMYSQL}
> +RUN_DEPENDS+=3D	sudo:security/sudo
> +.if ${PORT_OPTIONS:MOPENLDAP}
> +RUN_DEPENDS+=3D	slapcat:net/openldap24-server
> +.endif
> +.if ${PORT_OPTIONS:MPGSQL}
> +USES+=3D	pgsql
> +RUN_DEPENDS+=3D	pg_dump:databases/postgresql${PGSQL_VER_NODOT}-client
> +RUN_DEPENDS+=3D	pg_dumpall:databases/postgresql${PGSQL_VER_NODOT}-client

Those three lines all do the same thing, except that the last two are
awful.

> +.endif
> +.if ${PORT_OPTIONS:MMYSQL}
> +USES+=3D	mysql
> +RUN_DEPENDS+=3D	mysqldump:${_MYSQL_CLIENT}

Same here, only the first is required.

> Added: head/sysutils/omnibackup/files/pkg-message.in
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- /dev/null	00:00:00 1970	(empty, because file is newly added)
> +++ head/sysutils/omnibackup/files/pkg-message.in	Wed Jul 18 12:48:33 201=
8	(r474859)
> @@ -0,0 +1,32 @@
> +########################################################################=
#######
> +
> +In order to run OmniBackup, you will need to create and configure the ma=
in
> +configuration file, e.g.:
> +
> +$ cp -p %%LOCALBASE%%/etc/omnibackup/config.json.sample \
> +      %%LOCALBASE%%/etc/omnibackup/config.json

This should be PREFIX, not LOCALBASE.

> +or, create it in the root users' home directory:
> +
> +$ cp -p %%LOCALBASE%%/etc/omnibackup/config.json.sample \
> +      %%ROOT_HOME%%/.omnibackup/config.json

This should be PREFIX.

> +In order to take automatic backups every 24 hours at 01:00am UTC run this
> +command:
> +
> +$ crontab -e -u root
> +
> +Then add the following lines to the root users' crontab:
> +
> +# OmniBackup daily backups
> +00      01      *       *       *       %%LOCALBASE%%/bin/omnibackup

PREFIX.

> +To avoid data loss, make sure to consult the documentation at:
> +
> +* %%LOCALBASE%%/share/doc/omnibackup/README.md

PREFIX

--=20
Mathieu Arnold

--lkntcoddxnhptn4q
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQKTBAABCgB9FiEEOraXidLtEhBkQLpbOkUW81GDzkgFAltPRpdfFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNB
QjY5Nzg5RDJFRDEyMTA2NDQwQkE1QjNBNDUxNkYzNTE4M0NFNDgACgkQOkUW81GD
zkjg0A/+Ml3tzhEsjCf/B9GEW5ze9Xu7yn4Ii0VYUbjkqUsRlb1nJ+UxPhr2eh9m
GdaZ8X2UoLWIFwbCAC7RsQV+odGKXTOX49oRe+bYgHRX74ckZUW6s39un7vvm7cO
+wJR3IuLBKGQXdUqIE+KG6WbnFSlOzSOKQwySFj143tQ21bwk0XeoqKoNzSP9alb
9rjmyXc9zCb28qvywbefvTA/SY8QWBc0Mwy4lfBO2afcKcODfZaT413Mv0gviE0A
q4slpOVmzCukdJBBIoK152vJuC1Nyip47y7if6qraAD+u0PxSXMbPKI6gVcn8req
OStorB2DAUV5HyCiXaLqG3wGarWwYrH9alK7gTc3m/nzcxl2vTgoV2aDbl/VAru4
vjDhqT7aF7cdEq7YjGKAf/tDRIhGhdNRKOkg2iE0nvCTQTQlrYOV65Abf+w60j2s
E69xrzoDZR8ZdGRl3Qdio1WLP2gvH5weg31cAzYsv/8XMUdnr+9Xe26hgqJkiUfI
N+vYGhc/dno/0ZlN7903ducSYiA7fNDQsK30vIbk3zpJSD392gRAi8E4w1eQJqDo
ohngELjmOVAgWyUsPESEcQyEn19vCKy84Bb4C5t11oNNPz2wzo7NfZDqVuGSKlj0
mfkczXhTqwBGr16etbobwHeJa/lNs+ZKhMKkn6U64h6gXyOvYhk=
=wErA
-----END PGP SIGNATURE-----

--lkntcoddxnhptn4q--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20180718135432.zkwre46ms6fnefeo>