Skip to content

Commit

Permalink
Merge pull request #63 from CESNET/devel
Browse files Browse the repository at this point in the history
Merge devel to master and bump version to 2.3.0
  • Loading branch information
Lukas955 authored Mar 11, 2022
2 parents 0744bcf + 83ac59d commit ee21c37
Show file tree
Hide file tree
Showing 51 changed files with 3,742 additions and 1,871 deletions.
39 changes: 28 additions & 11 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,19 @@ jobs:
strategy:
fail-fast: false
matrix:
image: ['ubuntu:18.04', 'ubuntu:20.04', 'debian:stretch', 'debian:buster', 'debian:bullseye', 'centos:7', 'centos:8']
image:
- 'ubuntu:18.04'
- 'ubuntu:20.04'
- 'debian:stretch'
- 'debian:buster'
- 'debian:bullseye'
- 'centos:7'
- 'quay.io/centos/centos:stream8'
- 'oraclelinux:8'

name: Build on ${{ matrix.image }}
container: ${{ matrix.image }}
steps:
- uses: actions/checkout@v1

# Dependencies ---------------------------------------------------------------------------
- name: Install dependencies for libfds and IPFIXcol2 (Ubuntu/Debian)
Expand All @@ -32,23 +39,33 @@ jobs:
apt-get -y install librdkafka-dev
env:
DEBIAN_FRONTEND: noninteractive
- name: Enable additional repositories (CentOS 8)
if: startsWith(matrix.image, 'centos:8')
- name: Enable additional repositories (CentOS Steam)
if: contains(matrix.image, 'centos:stream')
run: |
dnf -y install 'dnf-command(config-manager)'
dnf config-manager --set-enabled appstream powertools
- name: Install dependencies for libfds and IPFIXcol2 (CentOS)
if: startsWith(matrix.image, 'centos')
- name: Enable additional repositories (Oracle Linux)
if: contains(matrix.image, 'oraclelinux')
run: |
dnf -y install 'dnf-command(config-manager)'
dnf config-manager --set-enabled ol8_appstream ol8_codeready_builder
- name: Enable EPEL (CentOS)
if: contains(matrix.image, 'centos')
run: |
yum -y install epel-release
- name: Enable EPEL (OracleLinux)
if: contains(matrix.image, 'oraclelinux')
run: |
dnf -y install oracle-epel-release-el8
- name: Install dependencies for libfds and IPFIXcol2 (CentOS, Oracle Linux)
if: contains(matrix.image, 'centos') || contains(matrix.image, 'oraclelinux')
run: |
yum -y install git gcc gcc-c++ cmake make libxml2-devel lz4-devel libzstd-devel
yum -y install zlib-devel pkgconfig librdkafka-devel
yum -y install python3-docutils || yum -y install python-docutils
- name: Install dependencies for libfds and IPFIXcol2 (Fedora)
if: startsWith(matrix.image, 'fedora')
run: |
dnf -y install git gcc gcc-c++ cmake make libxml2-devel lz4-devel libzstd-devel
dnf -y install python3-docutils zlib-devel pkgconfig librdkafka-devel
# Checkout repository --------------------------------------------------------------------
- uses: actions/checkout@v2

# Build libfds library ------------------------------------------------------------------
# Note: Master against master branch. Otherwise against debug branch.
Expand Down
97 changes: 58 additions & 39 deletions .github/workflows/packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,19 @@ jobs:
container: ${{ matrix.image }}

steps:
- uses: actions/checkout@v1
- name: Define global variables
run: echo "::set-output name=zip_file::ipfixcol2-${IMAGE//:/}-$GITHUB_SHA.zip"
shell: bash
env:
IMAGE: ${{ matrix.image }}
id: vars
- uses: actions/checkout@v2
- name: Define variables
uses: actions/github-script@v5
with:
script: |
const sha = context.sha.substring(0, 8);
const image = `${{ matrix.image }}`
const distro = image.split('/').pop().replace(/:/g,'_');
const zip = `ipfixcol2-${distro}-${sha}`;
core.exportVariable('ZIP_FILE', zip);
- name: Prepare environment
run: |
mkdir -p build/libfds_repo
# Dependencies ---------------------------------------------------------------------------
- name: Install dependencies for libfds and IPFIXcol2 (Ubuntu/Debian)
Expand Down Expand Up @@ -67,57 +73,73 @@ jobs:
ipfixcol2 -V
ipfixcol2 -h
ipfixcol2 -L
- name: Pack IPFIXcol2 DEB packages
working-directory: 'build/pkg/deb/debbuild/'
run: zip "$GITHUB_WORKSPACE/$ZIP_FILE" *.deb *.ddeb *.tar.gz *.dsc
env:
ZIP_FILE: ${{ steps.vars.outputs.zip_file }}
- name: Archive DEB packages
if: github.event_name == 'push'
uses: actions/upload-artifact@v1
uses: actions/upload-artifact@v2
with:
name: ${{ steps.vars.outputs.zip_file }}
path: ${{ steps.vars.outputs.zip_file }}
name: ${{ env.ZIP_FILE }}
path: |
build/pkg/deb/debbuild/*.deb
build/pkg/deb/debbuild/*.ddeb
build/pkg/deb/debbuild/*.tar.gz
build/pkg/deb/debbuild/*.dsc
rpm:
# Try to build RPM packages
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
image: ['centos:7', 'centos:8']
image:
- 'centos:7'
- 'quay.io/centos/centos:stream8'
- 'oraclelinux:8'

name: Build RPMs on ${{ matrix.image }}
container: ${{ matrix.image }}

steps:
- uses: actions/checkout@v1
- name: Prepare environment and variables
- name: Define variables
uses: actions/github-script@v5
with:
script: |
const sha = context.sha.substring(0, 8);
const image = `${{ matrix.image }}`
const distro = image.split('/').pop().replace(/:/g,'_');
const zip = `ipfixcol2-${distro}-${sha}`;
core.exportVariable('ZIP_FILE', zip);
- name: Prepare environment
run: |
echo "::set-output name=zip_file::ipfixcol2-${IMAGE//:/}-$GITHUB_SHA.zip"
mkdir -p build/libfds_repo
env:
IMAGE: ${{ matrix.image }}
id: vars
# Dependencies ---------------------------------------------------------------------------
- name: Enable additional repositories (CentOS 8)
if: startsWith(matrix.image, 'centos:8')
- name: Enable additional repositories (CentOS Stream)
if: contains(matrix.image, 'centos:stream')
run: |
dnf -y install 'dnf-command(config-manager)'
dnf config-manager --set-enabled appstream powertools
- name: Install dependencies for libfds and IPFIXcol2 (CentOS)
if: startsWith(matrix.image, 'centos')
- name: Enable additional repositories (Oracle Linux)
if: contains(matrix.image, 'oraclelinux')
run: |
dnf -y install 'dnf-command(config-manager)'
dnf config-manager --set-enabled ol8_appstream ol8_codeready_builder
- name: Enable EPEL (CentOS)
if: contains(matrix.image, 'centos')
run: |
yum -y install epel-release
- name: Enable EPEL (OracleLinux)
if: contains(matrix.image, 'oraclelinux')
run: |
dnf -y install oracle-epel-release-el8
- name: Install dependencies for libfds and IPFIXcol2 (CentOS, Oracle Linux)
if: contains(matrix.image, 'centos') || contains(matrix.image, 'oraclelinux')
run: |
yum -y install git gcc gcc-c++ cmake make libxml2-devel lz4-devel libzstd-devel
yum -y install zlib-devel pkgconfig rpm-build librdkafka-devel
yum -y install python3-docutils || yum -y install python-docutils
- name: Install depedencies for libfds and IPFIXcol2 (Fedora)
if: startsWith(matrix.image, 'fedora')
run: |
dnf -y install git gcc gcc-c++ cmake make libxml2-devel lz4-devel libzstd-devel
dnf -y install python3-docutils zlib-devel pkgconfig rpm-build librdkafka-devel
# Checkout repository --------------------------------------------------------------------
- uses: actions/checkout@v2

# Build LIBFDS RPM package ---------------------------------------------------------------
- name: Checkout libfds library - master branch
Expand Down Expand Up @@ -146,14 +168,11 @@ jobs:
ipfixcol2 -V
ipfixcol2 -h
ipfixcol2 -L -v
- name: Pack IPFIXcol2 RPM packages
working-directory: 'build/pkg/rpm/rpmbuild'
run: zip -r "$GITHUB_WORKSPACE/$ZIP_FILE" RPMS SRPMS
env:
ZIP_FILE: ${{ steps.vars.outputs.zip_file }}
- name: Archive RPM packages
if: github.event_name == 'push'
uses: actions/upload-artifact@v1
uses: actions/upload-artifact@v2
with:
name: ${{ steps.vars.outputs.zip_file }}
path: ${{ steps.vars.outputs.zip_file }}
name: ${{ env.ZIP_FILE }}
path: |
build/pkg/rpm/rpmbuild/RPMS/
build/pkg/rpm/rpmbuild/SRPMS/
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ endif()

# Versions and other informations
set(IPFIXCOL_VERSION_MAJOR 2)
set(IPFIXCOL_VERSION_MINOR 2)
set(IPFIXCOL_VERSION_MINOR 3)
set(IPFIXCOL_VERSION_PATCH 0)
set(IPFIXCOL_VERSION
${IPFIXCOL_VERSION_MAJOR}.${IPFIXCOL_VERSION_MINOR}.${IPFIXCOL_VERSION_PATCH})
Expand Down
12 changes: 10 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -86,15 +86,23 @@ Second, install build dependencies of the collector
yum install gcc gcc-c++ cmake make python3-docutils zlib-devel librdkafka-devel
# Optionally: doxygen pkgconfig
* Note: latest systems (e.g. Fedora/CentOS 8) use ``dnf`` instead of ``yum``.
* Note: latest systems (e.g. Fedora/CentOS Stream 8) use ``dnf`` instead of ``yum``.
* Note: package ``python3-docutils`` may by also named as ``python-docutils`` or ``python2-docutils``
* Note: package ``pkgconfig`` may by also named as ``pkg-config``
* Note: CentOS 8 requires additional system repositories (``appstream`` and ``powertools``) to be enabled:
* Note: CentOS Stream 8 usually requires additional system repositories to be enabled:

.. code-block::
dnf -y install epel-release
dnf config-manager --set-enabled appstream powertools
* Note: Oracle Linux 8 usually requires additional system repositories to be enabled:

.. code-block::
dnf -y install oracle-epel-release-el8
dnf config-manager --set-enabled ol8_appstream ol8_codeready_builder
**Debian/Ubuntu:**

.. code-block::
Expand Down
4 changes: 4 additions & 0 deletions extra_plugins/output/unirec/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,10 @@ Parameters
Specification of interface type and its parameters. For more details, see section
"Output interface types".

:``mappingFile``:
Path to configuration file with mapping IPFIX fields to UniRec fields. If the parameter is
not defined, the default configuration file is used. See section "UniRec configuration file".

Output interface types
----------------------
Exactly one of the following output type must be defined in the instance configuration of this
Expand Down
Loading

0 comments on commit ee21c37

Please sign in to comment.