* Changed config and install options for Restconf

* clixon_restconf daemon is installed in /usr/local/sbin (as clixon_backend), instead of /www-data
    * `configure --with-wwwdir=<dir>` remains but only applies to fcgi socket and log
    * New option `CLICON_RESTCONF_INSTALL_DIR` is set to where clixon_restconf is installed, with default `/usr/local/sbin/`
  * Restconf drop privileges user is defined by `CLICON_RESTCONF_USER`
    * `configure --with-wwwuser=<user>` is removed
  * clixon_restconf drop of privileges is defined by `CLICON_RESTCONF_PRIVILEGES` option
* New clixon-restconf@2020-05-20.yang revision
  * Added: restconf `log-destination`
This commit is contained in:
Olof hagsand 2021-05-21 15:12:06 +02:00
parent c3e26b004c
commit c20c672d83
32 changed files with 410 additions and 221 deletions

29
configure vendored
View file

@ -635,7 +635,6 @@ CXXFLAGS
CXX
CPP
wwwdir
wwwuser
enable_optyangs
with_libxml2
with_restconf
@ -719,7 +718,6 @@ with_cligen
enable_optyangs
enable_publish
with_restconf
with_wwwuser
with_configfile
with_libxml2
with_yang_installdir
@ -1376,7 +1374,6 @@ Optional Packages:
nginx (default)
--with-restconf=native Integrate restconf with embedded http server
--without-restconf Disable restconf altogether
--with-wwwuser=<user> Set www user different from www-data
--with-configfile=FILE Set default path to config file
--with-libxml2 Use gnome/libxml2 regex engine
--with-yang-installdir=DIR
@ -3355,9 +3352,6 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
# Set to native or fcgi -> compile apps/restconf
# Web user default (ie what RESTCONF daemon runs as).
wwwuser=www-data
# Home dir for web user
wwwdir=/www-data
@ -5298,24 +5292,6 @@ fi
# Common actions for all restconf packages
if test "x${with_restconf}" != "x"; then
# Web user default (ie what RESTCONF daemon runs as). Default: www-data
# Should this be a runtime option?
# Check whether --with-wwwuser was given.
if test "${with_wwwuser+set}" = set; then :
withval=$with_wwwuser;
fi
if test "${with_wwwuser}"; then
wwwuser=${with_wwwuser}
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: www user is $wwwuser" >&5
$as_echo "www user is $wwwuser" >&6; }
cat >>confdefs.h <<_ACEOF
#define WWWUSER "$wwwuser"
_ACEOF
cat >>confdefs.h <<_ACEOF
#define WWWDIR "$wwwdir"
@ -5323,11 +5299,6 @@ _ACEOF
else
cat >>confdefs.h <<_ACEOF
#define WWWUSER ""
_ACEOF
cat >>confdefs.h <<_ACEOF
#define WWWDIR ""
_ACEOF