Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
19 changes: 8 additions & 11 deletions Dockerfile.build
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
FROM debian:buster
FROM debian:bookworm

## Make apt-get non-interactive
ENV DEBIAN_FRONTEND=noninteractive

RUN echo "deb http://archive.debian.org/debian buster-backports main" >> /etc/apt/sources.list

RUN apt-get update \
&& apt-get install -y \
wget \
Expand All @@ -17,15 +15,16 @@ RUN apt-get update \
flex \
g++ \
git \
libboost-serialization1.71-dev \
libboost-serialization1.74-dev \
libhiredis-dev \
libzmq5-dev \
libevent-dev \
libssl-dev \
libtool \
make \
sudo \
pkg-config
pkg-config \
eatmydata

COPY debs /debs
RUN dpkg -i /debs/*.deb || apt-get --fix-broken -y install
Expand All @@ -41,12 +40,10 @@ RUN rm -fr /debs
# && make \
# && make install

RUN export VERSION=1.15 \
&& cd /tmp \
&& wget https://storage.googleapis.com/golang/go$VERSION.linux-amd64.tar.gz \
&& tar -C /usr/local -xzf go$VERSION.linux-amd64.tar.gz \
&& rm -fr /go \
&& mkdir -m 0666 /go
RUN eatmydata apt-get install -y golang

RUN eatmydata apt-get install -y golang-go \
&& ln -sf /usr/lib/go-1.19 /usr/local/go

ENV GOROOT=/usr/local/go
ENV PATH=$PATH:$GOROOT/bin
Expand Down
9 changes: 4 additions & 5 deletions Dockerfile.test
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
FROM debian:buster
FROM debian:bookworm

## Make apt-get non-interactive
ENV DEBIAN_FRONTEND=noninteractive

RUN echo "deb http://archive.debian.org/debian buster-backports main" >> /etc/apt/sources.list

RUN apt-get update \
&& apt-get install -y \
vim \
Expand All @@ -14,7 +12,7 @@ RUN apt-get update \
bridge-utils \
net-tools \
procps \
libboost-serialization1.71-dev \
libboost-serialization1.74-dev \
libzmq5-dev

COPY debs /debs
Expand All @@ -27,7 +25,8 @@ RUN sed -ri 's/^(save .*$)/# \1/g;
s/^logfile .*$/logfile ""/; \
s/^# syslog-enabled no$/syslog-enabled no/; \
s/^client-output-buffer-limit pubsub [0-9]+mb [0-9]+mb [0-9]+/client-output-buffer-limit pubsub 0 0 0/; \
s/^bind 127.0.0.1/bind 0.0.0.0/ \
s/^bind 127.0.0.1/bind 0.0.0.0/; \
s/^protected-mode yes/protected-mode no/ \
' /etc/redis/redis.conf

COPY supervisor/redis.conf /etc/supervisor/conf.d/
Expand Down
7 changes: 4 additions & 3 deletions azurepipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ pr:
jobs:
- job: Build
pool:
vmImage: ubuntu-20.04
vmImage: ubuntu-22.04

variables:
DIFF_COVER_CHECK_THRESHOLD: 80
Expand Down Expand Up @@ -42,6 +42,7 @@ jobs:
docker exec rest-api cat /tmp/rest-api.err.log
docker exec rest-api ps aux
sleep 600
docker exec rest-api supervisorctl stop rest-api
cd ..
docker cp rest-api:/coverage.cov ./
docker run -d --rm=true --name rest-api_build -v /tmp/target:/src -v $(pwd):/src/rest -w /src/rest rest-api-build-image tail -f /dev/null
Expand All @@ -57,9 +58,9 @@ jobs:
set -ex
# Install .NET CORE
curl -sSL https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
sudo apt-add-repository https://packages.microsoft.com/ubuntu/20.04/prod
sudo apt-add-repository https://packages.microsoft.com/ubuntu/22.04/prod
sudo apt-get update
sudo apt-get install -y dotnet-sdk-5.0
sudo apt-get install -y dotnet-sdk-8.0
displayName: "Install .NET CORE"

- task: PublishCodeCoverageResults@1
Expand Down
2 changes: 1 addition & 1 deletion cover.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ cp -r go-server-server $GOPATH/src/go-server-server

go tool cover -html=coverage.cov -o=htmlcov/coverage.html

go get github.com/t-yuki/gocover-cobertura
go install github.com/t-yuki/gocover-cobertura@latest
$GOPATH/bin/gocover-cobertura < coverage.cov > coverage.xml
12 changes: 6 additions & 6 deletions dependencies.conf
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"branch": "master",
"platform": "vs",
"debian": "buster",
"debian": "bookworm",
"arch": "amd64",
"dependencies": [
"libnl-3-200_3.5.0-1",
"libnl-3-dev_3.5.0-1",
"libnl-genl-3-200_3.5.0-1",
"libnl-route-3-200_3.5.0-1",
"libnl-nf-3-200_3.5.0-1",
"libnl-3-200_3.7.0-0.2+b1sonic1",
"libnl-3-dev_3.7.0-0.2+b1sonic1",
"libnl-genl-3-200_3.7.0-0.2+b1sonic1",
"libnl-route-3-200_3.7.0-0.2+b1sonic1",
"libnl-nf-3-200_3.7.0-0.2+b1sonic1",
"libyang_1.0.73",
"libswsscommon_1.0.0",
"libswsscommon-dev_1.0.0"
Expand Down
Loading