diff --git a/.github/workflows/k8s-snap-integration.yaml b/.github/workflows/k8s-snap-integration.yaml index c23b0cbf..02a9f764 100644 --- a/.github/workflows/k8s-snap-integration.yaml +++ b/.github/workflows/k8s-snap-integration.yaml @@ -15,7 +15,7 @@ concurrency: jobs: build: name: K8s-snap Integration Test - runs-on: ubuntu-20.04 + runs-on: self-hosted-linux-amd64-jammy-large steps: - name: Checking out repo @@ -23,7 +23,7 @@ jobs: - name: Setup Python uses: actions/setup-python@v5 with: - python-version: "3.8" + python-version: "3.10" - name: Install tox run: pip install tox - name: Install Go @@ -34,11 +34,7 @@ jobs: run: | sudo snap download k8s --channel=latest/edge --basename k8s - name: Install lxd - run: | - sudo snap refresh lxd --channel 5.21/stable - sudo lxd init --auto - sudo usermod --append --groups lxd $USER - sg lxd -c 'lxc version' + uses: canonical/k8s-snap/.github/actions/install-lxd@main - name: Build k8s-dqlite run: | make static diff --git a/.github/workflows/performance.yaml b/.github/workflows/performance.yaml index 5fc5f600..ecafc1ab 100644 --- a/.github/workflows/performance.yaml +++ b/.github/workflows/performance.yaml @@ -21,7 +21,7 @@ env: jobs: build: name: K8s-snap Performance Test - runs-on: ubuntu-20.04 + runs-on: self-hosted-linux-amd64-jammy-large steps: - name: Harden Runner uses: step-security/harden-runner@v2 @@ -42,20 +42,10 @@ jobs: go-version: "1.22" - name: Set-up R run: | - sudo apt install r-base + sudo apt-get install -y r-base sudo Rscript -e 'install.packages(c("ggplot2", "dplyr", "optparse"), repos="https://cloud.r-project.org")' - name: Install lxd - run: | - sudo snap refresh lxd --channel 5.21/stable - sudo lxd init --auto - sudo usermod --append --groups lxd $USER - sg lxd -c 'lxc version' - - name: Ensure lxd network traffic flows by removing docker if installed - run: | - if command -v docker >/dev/null 2>&1; then - echo "Docker is installed, purging it" - sudo apt-get purge -y docker-engine docker docker.io docker-ce docker-ce-cli containerd runc - fi + uses: canonical/k8s-snap/.github/actions/install-lxd@main - name: Download latest k8s-snap run: | sudo snap download k8s --channel=latest/edge --basename k8s diff --git a/pkg/kine/server/get.go b/pkg/kine/server/get.go index 03daeb4a..7990237a 100644 --- a/pkg/kine/server/get.go +++ b/pkg/kine/server/get.go @@ -23,13 +23,6 @@ func (l *LimitedServer) get(ctx context.Context, r *etcdserverpb.RangeRequest) ( attribute.Int64("revision", r.Revision), ) - if len(r.RangeEnd) != 0 { - return nil, fmt.Errorf("unexpected rangeEnd: want empty, got %s", r.RangeEnd) - } - if r.Limit != 0 { - return nil, fmt.Errorf("unexpected limit: want 0, got %d", r.Limit) - } - rev, kv, err := l.backend.List(ctx, string(r.Key), "", 1, r.Revision) if err != nil { return nil, err