]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
install: create runtime data directory
authorJason Ish <jason.ish@oisf.net>
Tue, 6 Jun 2023 21:32:18 +0000 (15:32 -0600)
committerVictor Julien <vjulien@oisf.net>
Wed, 14 Jun 2023 05:10:57 +0000 (07:10 +0200)
On installation, make sure the data directory is created. This will
usually be /var/lib/suricata/data, but otherwise follows the
autoconf/automake instructions.

This directory is for runtime state information, which for now is
datasets but may be expanded in the future.  Suricata already expects
this directory to exist for "state" and "save" datasets, but it has
been up to the user to create it.

Makefile.am
configure.ac

index a5a71f710efc069bf55153cfa5332b4c6f586c3e..9bf75c95010cedd9bda9ed1287b654294efefd3f 100644 (file)
@@ -31,6 +31,7 @@ install-conf:
        install -d "$(DESTDIR)$(e_logcertsdir)"
        install -d "$(DESTDIR)$(e_rundir)"
        install -m 770 -d "$(DESTDIR)$(e_localstatedir)"
+       install -m 770 -d "$(DESTDIR)$(e_datadir)"
 
 install-rules:
 if INSTALL_SURICATA_UPDATE
index 03800c371734808a8f6d15772a38cee6dc580945..c4afb2b95c15a9c642820c3fd24d3cff3a60e359 100644 (file)
@@ -2562,6 +2562,7 @@ AC_SUBST(e_logcertsdir)
 AC_SUBST(e_sysconfdir)
 AC_DEFINE_UNQUOTED([CONFIG_DIR],["$e_sysconfdir"],[Our CONFIG_DIR])
 AC_SUBST(e_localstatedir)
+AC_SUBST(e_datadir)
 AC_DEFINE_UNQUOTED([DATA_DIR],["$e_datadir"],[Our DATA_DIR])
 AC_SUBST(e_magic_file)
 AC_SUBST(e_magic_file_comment)