Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
728443a
chore(netifyd): update to v5
Tbaile Jul 30, 2025
5c0c2f2
chore: netify packages bump
Tbaile Oct 14, 2025
4daa376
refactor: using new format for netifyd v5
Tbaile Oct 14, 2025
d865752
fix: few path adjustments
Tbaile Oct 14, 2025
36e10f7
refactor: configuring netifyd packages
Tbaile Oct 16, 2025
3dc2448
chore: version bump
Tbaile Oct 17, 2025
5b67c45
refactor: official v5 revision
Tbaile Nov 5, 2025
4ab7349
fix: enable missing packages
Tbaile Nov 5, 2025
63fbe14
fix: avoid removing old config if not present
Tbaile Nov 5, 2025
8606699
feat: installed http sink
Tbaile Nov 5, 2025
014d86a
fix: removed symlinks
Tbaile Nov 5, 2025
dabd3ae
mistakenly deleted migration script
Tbaile Nov 6, 2025
96bad82
added config files and nft table
Tbaile Nov 6, 2025
51058a7
added informatics migration
Tbaile Nov 6, 2025
3368626
using new informatics status
Tbaile Nov 6, 2025
79700e2
fixed update script
Tbaile Nov 7, 2025
36d23ac
added license download
Tbaile Nov 12, 2025
be82b27
added ns-plug config reload after edit
Tbaile Nov 13, 2025
bf7b543
using new triggers for license
Tbaile Nov 13, 2025
8f2e527
rough finish of license work
Tbaile Nov 14, 2025
0b4d5d4
added switch to community-enterprise
Tbaile Nov 14, 2025
09c3dc7
renamed endpoint
Tbaile Nov 17, 2025
4028714
extended cronjob
Tbaile Nov 19, 2025
6d72b8c
fixed pathing
Tbaile Nov 19, 2025
25f3c50
trying to update package instead of re-flashing system
Tbaile Nov 20, 2025
8466b1e
updated package deps
Tbaile Nov 21, 2025
08e0a54
fixed update path
Tbaile Nov 21, 2025
927d557
since refresh now is every day and not every 10 minutes, force download
Tbaile Nov 24, 2025
0aa30f6
removed unneeded interfaces
Tbaile Nov 25, 2025
0a9bd98
moving binaries on DO
Tbaile Dec 4, 2025
179a287
moved files to DO
Tbaile Dec 5, 2025
dd0ef5f
chore(python3-nethsec): version bump
Tbaile Dec 17, 2025
1ece0f4
fix: forgot to update ns-api
Tbaile Dec 17, 2025
7e88aa4
fixing upgrade path
Tbaile Dec 17, 2025
9bb9d07
fix: add the base config only when updating, let cron be set
Tbaile Dec 18, 2025
9d41089
fixed startup app update
Tbaile Dec 18, 2025
b9a5f4a
flushing nft elements on restart
Tbaile Dec 19, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions .github/workflows/build-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ jobs:
env:
USIGN_PUB_KEY: ${{ secrets.USIGN_PUB_KEY }}
USIGN_PRIV_KEY: ${{ secrets.USIGN_PRIV_KEY }}
NETIFYD_ACCESS_TOKEN: ${{ secrets.NETIFYD_ACCESS_TOKEN }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
steps:
Expand All @@ -52,13 +51,6 @@ jobs:
# export NETHSECURITY_VERSION from build
echo "NETHSECURITY_VERSION=$(grep -oP 'NETHSECURITY_VERSION=\K.*' build.conf.example)" >> $GITHUB_OUTPUT

# if NETIFYD_ACCESS_TOKEN is set, set NETIFYD_ENABLED to 1
if [[ -n "${{ env.NETIFYD_ACCESS_TOKEN }}" ]]; then
echo "NETIFYD_ENABLED=1" >> $GITHUB_OUTPUT
else
echo "NETIFYD_ENABLED=0" >> $GITHUB_OUTPUT
fi

# When pushing a tag, set REPO_CHANNEL to stable
if [[ "${{ github.ref }}" == refs/tags/* ]]; then
echo "REPO_CHANNEL=stable" >> $GITHUB_OUTPUT
Expand All @@ -82,7 +74,6 @@ jobs:
OWRT_VERSION: ${{ steps.build_vars.outputs.OWRT_VERSION }}
NETHSECURITY_VERSION: ${{ steps.build_vars.outputs.NETHSECURITY_VERSION }}
REPO_CHANNEL: ${{ steps.build_vars.outputs.REPO_CHANNEL }}
NETIFYD_ENABLED: ${{ steps.build_vars.outputs.NETIFYD_ENABLED }}
TARGET: ${{ steps.build_vars.outputs.TARGET }}
run: ./build-nethsec.sh
- name: Update latest_release file
Expand Down
5 changes: 0 additions & 5 deletions build-nethsec.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@ OWRT_VERSION=${OWRT_VERSION:?Missing OWRT_VERSION environment variable}
NETHSECURITY_VERSION=${NETHSECURITY_VERSION:?Missing NETHSECURITY_VERSION environment variable}
REPO_CHANNEL=${REPO_CHANNEL:-dev}
TARGET=${TARGET:-x86_64}
NETIFYD_ENABLED=${NETIFYD_ENABLED:-0}
NETIFYD_ACCESS_TOKEN=${NETIFYD_ACCESS_TOKEN}

if [ -f "./key-build" ] && [ -f "./key-build.pub" ]; then
USIGN_PRIV_KEY="$(cat ./key-build)"
Expand All @@ -40,7 +38,6 @@ podman build \
--build-arg REPO_CHANNEL="$REPO_CHANNEL" \
--build-arg TARGET="$TARGET" \
--build-arg NETHSECURITY_VERSION="$NETHSECURITY_VERSION" \
--build-arg NETIFYD_ENABLED="$NETIFYD_ENABLED" \
.

set +e
Expand All @@ -49,8 +46,6 @@ status=0
podman run \
--env USIGN_PRIV_KEY="$USIGN_PRIV_KEY" \
--env USIGN_PUB_KEY="$USIGN_PUB_KEY" \
--env NETIFYD_ENABLED="$NETIFYD_ENABLED" \
--env NETIFYD_ACCESS_TOKEN="$NETIFYD_ACCESS_TOKEN" \
--name nethsecurity-builder \
--interactive \
--tty \
Expand Down
2 changes: 0 additions & 2 deletions build.conf.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,3 @@ OWRT_VERSION=v24.10.3
NETHSECURITY_VERSION=8.7.1
TARGET=x86_64
REPO_CHANNEL=dev
NETIFYD_ENABLED=0
NETIFYD_ACCESS_TOKEN=
1 change: 0 additions & 1 deletion builder/Containerfile
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ ARG REPO_CHANNEL
ARG TARGET
ARG NETHSECURITY_VERSION
COPY --chmod=777 builder/configure-build.sh /usr/local/bin/configure-build
ARG NETIFYD_ENABLED=0
RUN /usr/local/bin/configure-build
COPY --chmod=777 builder/entrypoint.sh /usr/local/bin/entrypoint.sh
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
Expand Down
15 changes: 0 additions & 15 deletions builder/configure-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,21 +39,6 @@ CONFIG_VERSION_SUPPORT_URL="https://community.nethserver.org"
EOF
cat "config/targets/${target}.conf" >> .config

# Netifyd closed-sources plugin
if [ "$NETIFYD_ENABLED" -eq "0" ]; then
echo "Netifyd closed-sources plugin not enabled: skipping ns-dpi package"
echo CONFIG_PACKAGE_ns-dpi=n >> .config
else
echo "Netifyd closed-sources plugin enabled: enabling ns-dpi package"
cat << EOF >> .config
CONFIG_PACKAGE_netify-flow-actions=y
CONFIG_NETIFY_FLOW_ACTIONS_TARGET_LOG=y
CONFIG_NETIFY_FLOW_ACTIONS_TARGET_CTLABEL=y
CONFIG_NETIFY_FLOW_ACTIONS_TARGET_NFTSET=y
CONFIG_PACKAGE_netify-plugin-stats=y
EOF
fi

# Write version information into a file
echo "${repo_channel}" > files/etc/repo-channel

Expand Down
6 changes: 0 additions & 6 deletions builder/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@

set -e

if [ ! "$NETIFYD_ENABLED" -eq "0" ]; then
echo "Netifyd is enabled, downloading sources..."
git clone "https://oauth2:$NETIFYD_ACCESS_TOKEN@gitlab.com/netify.ai/private/nethesis/netify-flow-actions.git"
git clone "https://oauth2:$NETIFYD_ACCESS_TOKEN@gitlab.com/netify.ai/private/nethesis/netify-agent-stats-plugin.git"
fi

if [ -n "$USIGN_PUB_KEY" ] && [ -n "$USIGN_PRIV_KEY" ]; then
echo "$USIGN_PUB_KEY" > /home/buildbot/openwrt/key-build.pub
echo "$USIGN_PRIV_KEY" > /home/buildbot/openwrt/key-build
Expand Down
21 changes: 2 additions & 19 deletions docs/build/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,20 +71,17 @@ The `build-nethsec.sh` script behavior can be changed by giving the following en
- `NETHSECURITY_VERSION`: specify what to call the NethSecurity image; **required**
- `TARGET`: specify the target to build; if not set default is `x86_64`
- `REPO_CHANNEL`: specify the channel to publish the image to; if not set default is `dev`
- `NETIFYD_ENABLED`: configure if netifyd plugins should be downloaded and compiled; if not set, default is `0` (disabled)
- `NETIFYD_ACCESS_TOKEN`: token to download the netifyd plugins; if not set, default is empty, required if `NETIFYD_ENABLED` is set to `1`
- `USIGN_PUB_KEY` and `USIGN_PRIV_KEY`: see [package signing section](#package-signing)
with the given keys

The `USIGN_PUB_KEY`, `USIGN_PRIV_KEY` and `NETIFYD_ACCESS_TOKEN` variables are always set as secrets
inside the CI pipeline, but for [security reasons](https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions#accessing-secrets)
The `USIGN_PUB_KEY`, `USIGN_PRIV_KEY` variables are always set as secrets inside the CI pipeline, but
for [security reasons](https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions#accessing-secrets)
they are not accessible when building pull requests from forks.

### Build locally for a release

If you need to build some packages locally for a release, make sure the following environment variables are set:
- `USIGN_PUB_KEY` and `USIGN_PRIV_KEY`: refer to the [package signing section](#package-signing) for more info
- `NETIFYD_ENABLED` and `NETIFYD_ACCESS_TOKEN`: required to download and compile netifyd closed source plugins

Then execute the build as described in the [Build locally](#build-locally) section.

Expand Down Expand Up @@ -282,20 +279,6 @@ Or you can have the keys as two files named `key-build` and `key-build.pub` in t

Builds executed inside CI will sign the packages with the correct key.

### Netifyd plugins

NethSecurity uses two [netifyd](https://gitlab.com/netify.ai/public/netify-agent) proprietary plugins from [Netify](https://www.netify.ai/):

- Netify Flow Actions Plugin (netify-flow-actions)
- Netify Agent Stats Plugin (netify-plugin-stats)

The plugins should be used with the latest netifyd stable version (4.4.3 at the time of writing).
To create the files for the build, follow the steps below. Such steps should be needed only after a netifyd/plugin version change.

Both plugins source code is hosted on a private repository at [GitLab](https://gitlab.com).
To access it, you must set `NETIFYD_ENABLED=1` and provide a personal access token with read access to the private repositories. And then `NETIFYD_ACCESS_TOKEN` environment variable must be set to the token value.


## Self-hosted runner

The build system uses a GitHub-hosted runner to build the images.
Expand Down
28 changes: 0 additions & 28 deletions packages/netify-flow-actions/Config.in

This file was deleted.

87 changes: 0 additions & 87 deletions packages/netify-flow-actions/Makefile

This file was deleted.

Loading
Loading