diff --git a/.github/workflows/binary.yml b/.github/workflows/binary.yml index 1718e8b..4b9f85f 100644 --- a/.github/workflows/binary.yml +++ b/.github/workflows/binary.yml @@ -16,13 +16,11 @@ jobs: uses: actions/checkout@v3 with: fetch-depth: 0 - - name: "Build binary" run: | sudo apt-get update sudo apt-get install -y build-essential libvirt-dev make genisoimage libguestfs-dev libcephfs-dev librbd-dev librados-dev make - - uses: actions/upload-artifact@v3 with: name: yavirt-ubuntu diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index a1f2622..115873e 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -20,11 +20,6 @@ jobs: uses: actions/setup-go@v5 with: go-version-file: 'go.mod' - - - name: "Install dependencies" - run: | - sudo apt-get update - sudo apt-get install -y build-essential libvirt-dev make genisoimage libguestfs-dev libcephfs-dev librbd-dev librados-dev - name: "Install dependencies" run: | diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0aee22b..9e7da7f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -21,15 +21,9 @@ jobs: uses: actions/setup-go@v5 with: go-version-file: 'go.mod' - - name: "Install dependencies" run: | sudo apt-get update sudo apt-get install -y build-essential libvirt-dev make genisoimage libguestfs-dev libcephfs-dev librbd-dev librados-dev - - name: "Install dependencies" - run: | - sudo apt-get update - sudo apt-get install -y build-essential libvirt-dev make genisoimage libguestfs-dev libcephfs-dev librbd-dev librados-dev - - name: unit tests run: make test diff --git a/Dockerfile b/Dockerfile index 93684ca..e26e86e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:jammy AS BUILD +FROM ubuntu:noble AS BUILD # make binary # RUN git clone https://github.com/projecteru2/yavirt.git /go/src/github.com/projecteru2/yavirt @@ -6,16 +6,15 @@ COPY . /go/src/github.com/projecteru2/yavirt WORKDIR /go/src/github.com/projecteru2/yavirt ARG KEEP_SYMBOL RUN apt update -RUN apt install -y golang-1.20 build-essential libvirt-dev make genisoimage libguestfs-dev libcephfs-dev librbd-dev librados-dev -RUN apt install -y git +RUN apt install -y golang-1.22 build-essential libvirt-dev make genisoimage libguestfs-dev libcephfs-dev librbd-dev librados-dev git # RUN snap install go --classic -ENV PATH="$PATH:/usr/lib/go-1.20/bin/" +ENV PATH="$PATH:/usr/lib/go-1.22/bin/" RUN go version RUN make deps RUN make && ./bin/yavirtd --version -FROM ubuntu:jammy +FROM ubuntu:noble RUN mkdir /etc/yavirt/ && \ apt update && \ diff --git a/go.mod b/go.mod index fda6566..ba2ef85 100644 --- a/go.mod +++ b/go.mod @@ -35,7 +35,7 @@ require ( github.com/pkg/errors v0.9.1 github.com/projectcalico/api v0.0.0-20230222223746-44aa60c2201f github.com/projectcalico/calico v1.11.0-cni-plugin.0.20230510161715-15d193738928 - github.com/projecteru2/core v0.0.0-20240613084815-dff459401ad7 + github.com/projecteru2/core v0.0.0-20240614132727-08e4fbc219d1 github.com/projecteru2/libyavirt v0.0.0-20231128023216-96fef06a6ca4 github.com/projecteru2/resource-storage v0.0.0-20230206062354-d828802f6b96 github.com/prometheus-community/pro-bing v0.4.0 @@ -150,7 +150,7 @@ require ( github.com/pmezard/go-difflib v1.0.0 // indirect github.com/projectcalico/go-json v0.0.0-20161128004156-6219dc7339ba // indirect github.com/projectcalico/go-yaml-wrapper v0.0.0-20191112210931-090425220c54 // indirect - github.com/projecteru2/vmihub v0.0.0-20240628073228-3417154bf02a // indirect + github.com/projecteru2/vmihub v0.0.0-20240702045253-4fa15dba054f // indirect github.com/prometheus/client_model v0.3.0 // indirect github.com/prometheus/common v0.42.0 // indirect github.com/prometheus/procfs v0.10.1 // indirect diff --git a/go.sum b/go.sum index e32823d..d1020d2 100644 --- a/go.sum +++ b/go.sum @@ -408,14 +408,14 @@ github.com/projectcalico/go-yaml-wrapper v0.0.0-20191112210931-090425220c54 h1:J github.com/projectcalico/go-yaml-wrapper v0.0.0-20191112210931-090425220c54/go.mod h1:UgC0aTQ2KMDxlX3lU/stndk7DMUBJqzN40yFiILHgxc= github.com/projectcalico/hcsshim v0.8.9-calico h1:aRrOWouDTzKwaIoRGMV/I1QikR+ikwj1G9T9h3wD090= github.com/projectcalico/hcsshim v0.8.9-calico/go.mod h1:5692vkUqntj1idxauYlpoINNKeqCiG6Sg38RRsjT5y8= -github.com/projecteru2/core v0.0.0-20240613084815-dff459401ad7 h1:VTQ/+U5Qhu7KpqZ3Z3naX7NlOpuMSwBG/uNMlSzprq0= -github.com/projecteru2/core v0.0.0-20240613084815-dff459401ad7/go.mod h1:JDOLwVw4EdLTk+bqI/LdU4Ix/Wl6BaaHMzaOO5vpU8U= +github.com/projecteru2/core v0.0.0-20240614132727-08e4fbc219d1 h1:ckh4IsnppXEbe9vb3Au4lKO5Z7ZNqanNBLdWViBdvxI= +github.com/projecteru2/core v0.0.0-20240614132727-08e4fbc219d1/go.mod h1:JDOLwVw4EdLTk+bqI/LdU4Ix/Wl6BaaHMzaOO5vpU8U= github.com/projecteru2/libyavirt v0.0.0-20231128023216-96fef06a6ca4 h1:3a0IhsOtH9J+iSn/DV7v9gpW2lBDGhkp+XEvTaSiK4g= github.com/projecteru2/libyavirt v0.0.0-20231128023216-96fef06a6ca4/go.mod h1:+EcdWF8KyTf2u8Zxu3397nSmalCSmpuxvGwcX1g3RL0= github.com/projecteru2/resource-storage v0.0.0-20230206062354-d828802f6b96 h1:mt8llWHpuOhPMIe7sOxr5jqYrVk4wE6eZ3cyAkj0+7o= github.com/projecteru2/resource-storage v0.0.0-20230206062354-d828802f6b96/go.mod h1:sdXwl7dPfO3UH8PPr7ELvEutJSAjOQOGlmkenfL6DfU= -github.com/projecteru2/vmihub v0.0.0-20240628073228-3417154bf02a h1:DE3fhCM/OKJs2Z9bkeNKDJCpnU0wubUXNYs4Jhl93AM= -github.com/projecteru2/vmihub v0.0.0-20240628073228-3417154bf02a/go.mod h1:h8beeiTyKvxMccTOXVcrJkYTrQer5DGi1Ve4p53bX24= +github.com/projecteru2/vmihub v0.0.0-20240702045253-4fa15dba054f h1:8fGN1Xfl4BdBG8CptO/p5TbQESwSYkRWG7aUxkBE91o= +github.com/projecteru2/vmihub v0.0.0-20240702045253-4fa15dba054f/go.mod h1:WiPPJSWUBR0qnO7L/bTC6q3Iwn8AUC3arJPMS31dEXM= github.com/prometheus-community/pro-bing v0.4.0 h1:YMbv+i08gQz97OZZBwLyvmmQEEzyfyrrjEaAchdy3R4= github.com/prometheus-community/pro-bing v0.4.0/go.mod h1:b7wRYZtCcPmt4Sz319BykUU241rWLe1VFXyiyWK/dH4= github.com/prometheus/client_golang v1.16.0 h1:yk/hx9hDbrGHovbci4BY+pRMfSuuat626eFsHb7tmT8=