From: Jonathan McDowell Date: Sun, 18 Aug 2019 19:46:39 +0000 (+0100) Subject: Deprecate the .conf configuration file format X-Git-Tag: onak-0.6.0~30 X-Git-Url: https://the.earth.li/gitweb/?p=onak.git;a=commitdiff_plain;h=eb94eab34a0893fb5b8f78652f338df85f492a9b Deprecate the .conf configuration file format The old .conf config file was intended to be compatible with the ancient PKS keyserver. All new features are only supported with the .ini format and this is going to make the automated tests supporting both more awkward. So deprecate the old style and stop testing it. --- diff --git a/onak-conf.c b/onak-conf.c index 8925dbc..7b8a2e3 100644 --- a/onak-conf.c +++ b/onak-conf.c @@ -391,6 +391,12 @@ void readconfig(const char *configfile) { conffile = fopen(configfile, "r"); } + if (oldstyle) { + logthing(LOGTHING_CRITICAL, "Reading deprecated old-style " + "configuration file. This will not be " + "supported in the next release."); + } + if (conffile != NULL) { if (!fgets(curline, 1023, conffile)) { logthing(LOGTHING_CRITICAL, diff --git a/runtests b/runtests index b65b6e0..60c0222 100755 --- a/runtests +++ b/runtests @@ -33,24 +33,7 @@ for t in libkeydb_*.so; do backend=${t##libkeydb_} backend=${backend%%.so} if [ "`echo ${TESTSDIR}/$backend-*`" != "${TESTSDIR}/$backend-*" ]; then - echo "* testing $backend backend [conf]" - (sed -e "s;BUILDDIR;${BUILDDIR};" -e "s;WORKDIR;${WORKDIR};" \ - ${TESTSDIR}/test-in.conf ; \ - echo db_backend $backend) > ${WORKDIR}/test.conf - for t in ${TESTSDIR}/$backend-*.t ${TESTSDIR}/all-*.t; do - total=`expr $total + 1` - mkdir ${WORKDIR}/db/ - if ! $t ${WORKDIR}/test.conf $backend; then - echo "test $t failed" >&2 - fail=`expr $fail + 1` - fi - rm -rf ${WORKDIR}/db/ - done - rm ${WORKDIR}/test.conf - fi - - if [ "`echo ${TESTSDIR}/$backend-*`" != "${TESTSDIR}/$backend-*" ]; then - echo "* testing $backend backend [ini]" + echo "* testing $backend backend" sed -e "s;BUILDDIR;${BUILDDIR};" -e "s;WORKDIR;${WORKDIR};" \ -e "s;DB;${backend};" \ ${TESTSDIR}/test-in.ini > ${WORKDIR}/test.ini diff --git a/t/test-in.conf b/t/test-in.conf deleted file mode 100644 index 329fc4c..0000000 --- a/t/test-in.conf +++ /dev/null @@ -1,8 +0,0 @@ -pks_bin_dir BUILDDIR -backends_dir BUILDDIR -db_dir WORKDIR/db/ -logfile onak.log -loglevel 7 -use_keyd false -this_site pgp-public-keys@localhost -max_reply_keys 128