diff --git a/.github/workflows/publish-docker-tester.yml b/.github/workflows/publish-docker-tester.yml index f6f7315a7..d23933c5b 100644 --- a/.github/workflows/publish-docker-tester.yml +++ b/.github/workflows/publish-docker-tester.yml @@ -68,7 +68,6 @@ jobs: version: latest endpoint: ${{ env.CONTEXT_NAME }} # self-hosted - name: Login to GHCR - if: github.event_name != 'pull_request' uses: docker/login-action@v3 with: registry: ghcr.io @@ -80,16 +79,26 @@ jobs: with: context: . platforms: ${{env.platforms}} - push: ${{ github.event_name != 'pull_request' }} + push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} target: tester secrets: | - "github_token=${{ secrets.BOT_PAT }}" + "github_token=${{ secrets.GITHUB_TOKEN }}" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} test: - runs-on: [ self-hosted, dpdk ] + runs-on: ubuntu-latest needs: buildAndPushTester steps: + - name: Configure Hugepages + run: | + ls -l /sys/kernel/mm/hugepages/ + cat /proc/meminfo + cat /proc/mounts | grep hugetlbfs + sudo sysctl -w vm.nr_hugepages=1024 + sudo mkdir -p /mnt/huge + sudo mount -t hugetlbfs nodev /mnt/huge - name: Determine SHA for Docker Image id: get_sha run: | @@ -101,4 +110,4 @@ jobs: - name: Run tests id: run_tests run: | - docker run --privileged --mount type=bind,source=/dev/hugepages,target=/dev/hugepages ghcr.io/ironcore-dev/dpservice-tester:${{ env.DOCKER_IMAGE_SHA }} + docker run -v /mnt/huge:/dev/hugepages ghcr.io/ironcore-dev/dpservice-tester:${{ env.DOCKER_IMAGE_SHA }} diff --git a/.github/workflows/publish-docker.yml b/.github/workflows/publish-docker.yml index 8325bd865..3028e904e 100644 --- a/.github/workflows/publish-docker.yml +++ b/.github/workflows/publish-docker.yml @@ -74,5 +74,3 @@ jobs: tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} target: production - secrets: | - "github_token=${{ secrets.BOT_PAT }}" diff --git a/Dockerfile b/Dockerfile index 8a6e0d139..8641f6f95 100644 --- a/Dockerfile +++ b/Dockerfile @@ -89,7 +89,6 @@ COPY .git/ .git/ # therefore downloading using 'ADD' is not possible RUN --mount=type=secret,id=github_token,dst=/run/secrets/github_token \ sh -c 'GITHUB_TOKEN=$(if [ -f /run/secrets/github_token ]; then cat /run/secrets/github_token; else echo ""; fi) \ -&& ./hack/rel_download.sh -dir=exporter -owner=ironcore-dev -repo=prometheus-dpdk-exporter -pat=$GITHUB_TOKEN \ && ./hack/rel_download.sh -dir=client -owner=ironcore-dev -repo=dpservice-cli -strip=2 -pat=$GITHUB_TOKEN' # Compile dpservice-bin itself