aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRuss Allbery <eagle@eyrie.org>2020-05-17 17:17:24 -0700
committerRuss Allbery <eagle@eyrie.org>2020-05-17 17:17:24 -0700
commit27662bbd5b1381e0e2b00e060bdb1c873cb22141 (patch)
tree3c0d1512e1c77fee62a904b2986bd20f9227e291
parentc138111a3c27863308b6552a5527a9e821a3dc11 (diff)
Switch to GitHub Actions for CI
Regenerate the documentation with patched DocKnot 3.04 to pick up the new status badge, which fixes a few other issues with documentation generation.
-rw-r--r--.github/workflows/build.yaml40
-rw-r--r--README8
-rw-r--r--README.md8
-rw-r--r--ci/README2
-rwxr-xr-xci/install39
-rwxr-xr-xci/test29
-rw-r--r--docs/metadata/metadata.json4
7 files changed, 124 insertions, 6 deletions
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
new file mode 100644
index 0000000..1d889ea
--- /dev/null
+++ b/.github/workflows/build.yaml
@@ -0,0 +1,40 @@
+name: build
+
+on:
+ push:
+ branches-ignore:
+ - "debian/**"
+ - "pristine-tar"
+ - "ubuntu/**"
+ - "upstream/**"
+ tags:
+ - "release/*"
+ pull_request:
+ branches:
+ - master
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+
+ env:
+ AUTHOR_TESTING: 1
+ C_TAP_VERBOSE: 1
+
+ strategy:
+ fail-fast: false
+ matrix:
+ compiler:
+ - "gcc"
+ kerberos:
+ - "mit"
+
+ steps:
+ - uses: actions/checkout@v2
+ - name: install
+ run: sudo ci/install
+ - name: test
+ run: ci/test
+ env:
+ COMPILER: ${{ matrix.compiler }}
+ KERBEROS: ${{ matrix.kerberos }}
diff --git a/README b/README
index c9a418f..2421f7b 100644
--- a/README
+++ b/README
@@ -99,10 +99,14 @@ REQUIREMENTS
included in MIT Kerberos 1.7 and later.
The WebAuth keyring object support in the wallet server requires the
- WebAuth Perl module from WebAuth 4.4.0 or later.
+ WebAuth Perl module from WebAuth 4.4.0 or later [2].
+
+ [2] https://www.eyrie.org/~eagle/software/webauth/
The Duo integration object support in the wallet server requires the
- Net::Duo, JSON, and Perl6::Slurp Perl modules.
+ Net::Duo [3], JSON, and Perl6::Slurp Perl modules.
+
+ [3] https://www.eyrie.org/~eagle/software/net-duo/
The password object support in the wallet server requires the
Crypt::GeneratePassword Perl module.
diff --git a/README.md b/README.md
index b1afe4e..5a375d9 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
# wallet 1.4
[![Build
-status](https://travis-ci.org/rra/wallet.svg?branch=master)](https://travis-ci.org/rra/wallet)
+status](https://github.com/rra/wallet/workflows/build/badge.svg)](https://github.com/rra/wallet/actions)
Copyright 2014, 2016, 2018 Russ Allbery <eagle@eyrie.org>. Copyright
2006-2010, 2012-2014 The Board of Trustees of the Leland Stanford Junior
@@ -99,10 +99,12 @@ supports the `-norandkey` option to `ktadd`. This option is included in
MIT Kerberos 1.7 and later.
The WebAuth keyring object support in the wallet server requires the
-WebAuth Perl module from WebAuth 4.4.0 or later.
+WebAuth Perl module from [WebAuth 4.4.0 or
+later](https://www.eyrie.org/~eagle/software/webauth/).
The Duo integration object support in the wallet server requires the
-Net::Duo, JSON, and Perl6::Slurp Perl modules.
+[Net::Duo](https://www.eyrie.org/~eagle/software/net-duo/), JSON, and
+Perl6::Slurp Perl modules.
The password object support in the wallet server requires the
Crypt::GeneratePassword Perl module.
diff --git a/ci/README b/ci/README
new file mode 100644
index 0000000..8b2dde6
--- /dev/null
+++ b/ci/README
@@ -0,0 +1,2 @@
+The files in this directory are used for CI testing. ci/install installs
+the prerequisite packages, and ci/test runs the tests.
diff --git a/ci/install b/ci/install
new file mode 100755
index 0000000..93fba76
--- /dev/null
+++ b/ci/install
@@ -0,0 +1,39 @@
+#!/bin/sh
+#
+# Install packages for integration tests.
+#
+# This script is normally run via sudo in a test container or VM, such as via
+# GitHub Actions.
+#
+# Perl::Tidy, Perl::Critic, and Test::Perl::Critic are installed separately to
+# get the latest version, since they sometimes change formatting and style
+# rules compared to the version in Ubuntu. Test::MinimumVersion has to be
+# included since it installs Perl::Critic.
+#
+# Allow the installation of Perl::Critic and Test::Perl::Critic to fail, since
+# sometimes the versions on CPAN won't install. (We'll just skip the test if
+# it won't install.)
+#
+# Copyright 2015-2020 Russ Allbery <eagle@eyrie.org>
+#
+# SPDX-License-Identifier: MIT
+
+set -eux
+
+# Install packages.
+apt-get update -qq
+apt-get install aspell cpanminus cppcheck heimdal-multidev \
+ libauthen-sasl-perl libcrypt-generatepassword-perl \
+ libdatetime-perl libdatetime-format-sqlite-perl \
+ libdbd-sqlite3-perl libdbi-perl libdbix-class-perl \
+ libheimdal-kadm5-perl libjson-perl libkrb5-dev libnet-dns-perl \
+ libnet-ldap-perl libnet-remctl-perl libperl6-slurp-perl \
+ libremctl-dev libsql-translator-perl libtest-pod-perl \
+ libtest-spelling-perl libtest-strict-perl libtimedate-perl \
+ libwebauth-perl perl sqlite3 valgrind
+
+# Dependencies for Perl tests.
+cpanm Perl::Tidy
+cpanm Perl::Critic || true
+cpanm Test::MinimumVersion || true
+cpanm Test::Perl::Critic || true
diff --git a/ci/test b/ci/test
new file mode 100755
index 0000000..efe4021
--- /dev/null
+++ b/ci/test
@@ -0,0 +1,29 @@
+#!/bin/sh
+#
+# Run tests for continuous integration.
+#
+# This script is normally run in a test container or VM, such as via GitHub
+# Actions.
+#
+# Copyright 2015-2020 Russ Allbery <eagle@eyrie.org>
+#
+# SPDX-License-Identifier: MIT
+
+set -eux
+
+# Normally, COMPILER and KERBEROS are set based on the CI matrix, but provide
+# a default in case someone runs this test by hand.
+COMPILER="${COMPILER:-gcc}"
+KERBEROS="${KERBEROS:-mit}"
+
+# Build everything.
+./bootstrap
+if [ "$KERBEROS" = 'heimdal' ]; then
+ ./configure CC="$COMPILER" PATH_KRB5_CONFIG=/usr/bin/krb5-config.heimdal
+else
+ ./configure CC="$COMPILER"
+fi
+make warnings
+
+# Run the tests.
+make check
diff --git a/docs/metadata/metadata.json b/docs/metadata/metadata.json
index 8d06621..f1d5074 100644
--- a/docs/metadata/metadata.json
+++ b/docs/metadata/metadata.json
@@ -38,7 +38,9 @@
"browse": "https://git.eyrie.org/?p=kerberos/wallet.git",
"github": "rra/wallet",
"openhub": "https://www.openhub.net/p/wallet",
- "travis": "rra/wallet",
+ "status": {
+ "workflow": "build",
+ },
},
"readme": {
"sections": [