-
Notifications
You must be signed in to change notification settings - Fork 1
/
barney.yaml
37 lines (34 loc) · 1.56 KB
/
barney.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Copyright (c) 2022 Arista Networks, Inc. All rights reserved.
# Arista Networks, Inc. Confidential and Proprietary.
images:
mfw_pkg/support-diagnostics:
units:
- floor: code.arista.io/mfw/build%toolchain
sources:
- code.arista.io/mfw/build
- github.com/untangle/openwrt
- github.com/untangle/mfw_feeds
- github.com/untangle/support-diagnostics
build: |
set -e
# copy build%toolchain's staging_dir into our source tree
cp -a /mfw-toolchain/staging_dir /src/github.com/untangle/openwrt/
# use barney-supplied feeds instead of fetching from github
perl -i -pe 's|^src-git mfw .+|src-link mfw /src/github.com/untangle/mfw_feeds|' /src/code.arista.io/mfw/build/feeds.conf.mfw
# barney sets DESTDIR to /dest, but this really confuses openwrt
unset DESTDIR
# build our package
cd /src/github.com/untangle/openwrt
/src/code.arista.io/mfw/build/build.sh -f /src -t "package/feeds/packages/python3/host/compile package/feeds/mfw/support-diagnostics/compile"
# copy resulting packages to destination image
mkdir -p /dest/mfw-packages/support-diagnostics
cp bin/packages/x86_64/*/* /dest/mfw-packages/support-diagnostics
cp bin/targets/x86/64/packages/* /dest/mfw-packages/support-diagnostics
test/mfw_pkg/support-diagnostics:
units:
- image: code.arista.io/mfw/build%world
- image: .%mfw_pkg/support-diagnostics
finalizers:
- - sh
- -c
- mkdir /var/lock && opkg install --force-downgrade /mfw-packages/*/*