diff --git a/.github/workflows/common-performance.yml b/.github/workflows/common-performance.yml index 7da41662..cc4c4d12 100644 --- a/.github/workflows/common-performance.yml +++ b/.github/workflows/common-performance.yml @@ -68,19 +68,10 @@ jobs: build-client: runs-on: vm-client env: - SERVER_ADDRESS: ${{ inputs.server_private_address }} GO_VERSION: 1.20.14 CMAKE_VERSION: '3.22.x' GH_TOKEN: ${{ github.token }} CACHE_KEY: qpep-${{ github.head_ref || github.ref_name }}-${{ github.sha }} - QPEP_REPO: https://github.com/${{github.repository}}.git - QPEP_BRANCH: ${{ github.head_ref || github.ref_name }} - QPEP_REV: ${{ github.sha }} - QPEP_GATEWAY: ${{ inputs.server_public_address }} - QPEP_ADDRESS: ${{ inputs.client_listen_address }} - QPEP_BACKEND: ${{ inputs.backend }} - QPEP_CCA: ${{ inputs.cca }} - QPEP_SLOWSTART: ${{ inputs.slowstart }} steps: - name: Install the github cli uses: sersoft-gmbh/setup-gh-cli-action@v2 @@ -181,19 +172,8 @@ jobs: runs-on: vm-client needs: [build-client, build-server] env: - SERVER_ADDRESS: ${{ inputs.server_private_address }} - GO_VERSION: 1.20.14 - CMAKE_VERSION: '3.22.x' GH_TOKEN: ${{ github.token }} CACHE_KEY: qpep-${{ github.head_ref || github.ref_name }}-${{ github.sha }} - QPEP_REPO: https://github.com/${{github.repository}}.git - QPEP_BRANCH: ${{ github.head_ref || github.ref_name }} - QPEP_REV: ${{ github.sha }} - QPEP_GATEWAY: ${{ inputs.server_public_address }} - QPEP_ADDRESS: ${{ inputs.client_listen_address }} - QPEP_BACKEND: ${{ inputs.backend }} - QPEP_CCA: ${{ inputs.cca }} - QPEP_SLOWSTART: ${{ inputs.slowstart }} strategy: max-parallel: 1 matrix: @@ -313,7 +293,6 @@ jobs: build-server: runs-on: vm-server env: - SERVER_ADDRESS: ${{ inputs.server_private_address }} GO_VERSION: 1.20.14 CMAKE_VERSION: '3.22.x' GH_TOKEN: ${{ github.token }} diff --git a/docker/server-env/docker-compose.yml b/docker/server-env/docker-compose.yml index e7444928..c184f66c 100644 --- a/docker/server-env/docker-compose.yml +++ b/docker/server-env/docker-compose.yml @@ -35,4 +35,4 @@ services: mode: host network_mode: "host" entrypoint: - - /root/run-qpep.sh + - /root/run-qpep.sh ${QPEP_REPO} ${QPEP_BRANCH} ${QPEP_REV} diff --git a/docker/server-env/server/Dockerfile b/docker/server-env/server/Dockerfile index b9694b51..517264d7 100644 --- a/docker/server-env/server/Dockerfile +++ b/docker/server-env/server/Dockerfile @@ -6,16 +6,15 @@ ENV CGO_ENABLED "1" ENV GOROOT "/opt/go" ENV GOPATH "/opt/gopath" ENV BUILDKIT_PROGRESS "plain" - -ARG QPEP_BACKEND="quic-go" -ARG QPEP_CCA="reno" -ARG QPEP_SLOWSTART="basic" -ARG QPEP_ADDRESS="127.0.0.1" -ARG QPEP_GATEWAY="127.0.0.1" -ARG GO_VERSION="1.20.14" -ARG QPEP_REPO="https://github.com/Project-Faster/qpep.git" -ARG QPEP_BRANCH="main" -ARG QPEP_REV="HEAD" +ENV QPEP_BACKEND="quic-go" +ENV QPEP_CCA="reno" +ENV QPEP_SLOWSTART="basic" +ENV QPEP_ADDRESS="127.0.0.1" +ENV QPEP_GATEWAY="127.0.0.1" +ENV GO_VERSION="1.20.14" +ENV QPEP_REPO="https://github.com/Project-Faster/qpep.git" +ENV QPEP_BRANCH="main" +ENV QPEP_REV="HEAD" USER root @@ -46,11 +45,11 @@ git submodule update \n\ ' > /root/clone-qpep.sh RUN printf '#!/bin/bash -xe \n\ -echo [UPDATE to ${QPEP_REPO}@${QPEP_BRANCH}:${QPEP_REV}] \n\ +echo [UPDATE to $1@$2:$3] \n\ cd /root/qpep \n\ -git switch ${QPEP_BRANCH} \n\ -if [[ ! "${QPEP_REV}" -eq "HEAD" ]]; then \n\ - git reset --hard ${QPEP_REV} \n\ +git switch $2 \n\ +if [[ ! "$3" -eq "HEAD" ]]; then \n\ + git reset --hard $3 \n\ fi \n\ git pull \n\ ' > /root/update-qpep.sh @@ -77,7 +76,7 @@ mkdir -p /opt/build/config \n\ WORKDIR /root RUN printf '#!/bin/bash -xe \n\ -/root/update-qpep.sh \n\ +/root/update-qpep.sh $1 $2 $3 \n\ /root/backends-qpep.sh \n\ /root/build-qpep.sh \n\ envsubst < /root/qpep/docker/server-env/server/config/qpep.yml.tpl > /opt/build/config/qpep.yml \n\ @@ -85,7 +84,7 @@ cat /opt/build/config/qpep.yml \n\ cp /root/qpep/docker/server-env/server/*.pem /opt/build/ \n\ ping -c 3 MQTT \n\ cd /opt/build \n\ -./qpep $1 \n\ +./qpep \n\ ' > /root/run-qpep.sh RUN sh -c 'dos2unix /root/*.sh'