mirror of
https://github.com/actions/actions-runner-controller.git
synced 2026-03-10 07:38:33 +08:00
Split e2e tests and rename copyExternals to copyRunnerExternals
This commit is contained in:
154
.github/workflows/gha-e2e-tests.yaml
vendored
154
.github/workflows/gha-e2e-tests.yaml
vendored
@@ -49,6 +49,22 @@ jobs:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
default-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run default setup test
|
||||
run: hack/e2e-test.sh default-setup-v2
|
||||
env:
|
||||
@@ -76,6 +92,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
single-namespace-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run single namespace setup test
|
||||
run: hack/e2e-test.sh single-namespace-setup-v2
|
||||
env:
|
||||
@@ -103,6 +136,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
dind-mode-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run dind mode setup test
|
||||
run: hack/e2e-test.sh dind-mode-setup
|
||||
env:
|
||||
@@ -130,6 +180,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
kubernetes-mode-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run kubernetes mode setup test
|
||||
run: hack/e2e-test.sh kubernetes-mode-setup
|
||||
env:
|
||||
@@ -157,6 +224,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
auth-proxy-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run single namespace setup test
|
||||
run: hack/e2e-test.sh single-namespace-setup
|
||||
env:
|
||||
@@ -184,6 +268,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
anonymous-proxy-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run anonymous proxy setup test
|
||||
run: hack/e2e-test.sh anonymous-proxy-setup
|
||||
env:
|
||||
@@ -211,6 +312,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
self-signed-ca-setup-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run self signed CA setup test
|
||||
run: hack/e2e-test.sh self-signed-ca-setup
|
||||
env:
|
||||
@@ -238,6 +356,23 @@ jobs:
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
update-strategy-tests-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run update strategy test
|
||||
run: hack/e2e-test.sh update-strategy
|
||||
env:
|
||||
@@ -266,8 +401,25 @@ jobs:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
|
||||
init-with-min-runners-v2:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 20
|
||||
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.id == github.repository_id
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
ref: ${{github.head_ref}}
|
||||
|
||||
- name: Get configure token
|
||||
id: config-token
|
||||
uses: peter-murray/workflow-application-token-action@d17e3a9a36850ea89f35db16c1067dd2b68ee343
|
||||
with:
|
||||
application_id: ${{ secrets.E2E_TESTS_ACCESS_APP_ID }}
|
||||
application_private_key: ${{ secrets.E2E_TESTS_ACCESS_PK }}
|
||||
organization: ${{ env.TARGET_ORG }}
|
||||
- name: Run init with min runners test
|
||||
run: hack/e2e-test.sh init-with-min-runners
|
||||
env:
|
||||
GITHUB_TOKEN: "${{steps.config-token.outputs.token}}"
|
||||
shell: bash
|
||||
shell: bash
|
||||
|
||||
|
||||
@@ -78,7 +78,7 @@ volumeMounts:
|
||||
{{- with $dindContainer.volumeMounts }}
|
||||
{{- toYaml . | nindent 2 }}
|
||||
{{- end }}
|
||||
{{- if $dind.copyExternals }}
|
||||
{{- if $dind.copyRunnerExternals }}
|
||||
- name: dind-externals
|
||||
mountPath: /home/runner/externals
|
||||
{{ end }}
|
||||
@@ -95,7 +95,7 @@ volumeMounts:
|
||||
- name: dind-sock
|
||||
emptyDir: {}
|
||||
{{ include "githubServerTLS.podVolumeItem" . }}
|
||||
{{- if .Values.runner.dind.copyExternals }}
|
||||
{{- if .Values.runner.dind.copyRunnerExternals }}
|
||||
- name: dind-externals
|
||||
emptyDir: {}
|
||||
{{- end }}
|
||||
@@ -163,4 +163,4 @@ value: {{ $waitForDockerInSecondsInt | toString | quote }}
|
||||
{{- end -}}
|
||||
{{- $dockerSockPath := trimPrefix "unix://" $dockerSock -}}
|
||||
{{- dir $dockerSockPath -}}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
@@ -181,7 +181,7 @@ spec:
|
||||
serviceAccountName: {{ include "autoscaling-runner-set.template-service-account" . | quote }}
|
||||
{{- if $hasInitContainers }}
|
||||
initContainers:
|
||||
{{- if and (eq $runnerMode "dind") $dind.copyExternals }}
|
||||
{{- if and (eq $runnerMode "dind") $dind.copyRunnerExternals }}
|
||||
- {{ include "runner-mode-dind.copy-externals" . | nindent 10 }}
|
||||
{{- end }}
|
||||
{{- range $extraInitContainers }}
|
||||
@@ -220,4 +220,4 @@ spec:
|
||||
{{- end }}
|
||||
{{- if gt (len $runnerPodSpecExtraFields) 0 }}
|
||||
{{- toYaml $runnerPodSpecExtraFields | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
@@ -114,7 +114,7 @@ tests:
|
||||
name: dind-externals
|
||||
emptyDir: {}
|
||||
|
||||
- it: should omit init-dind-externals and dind-externals volume when copyExternals is false
|
||||
- it: should omit init-dind-externals and dind-externals volume when copyRunnerExternals is false
|
||||
set:
|
||||
scaleset.name: "test"
|
||||
auth.url: "https://github.com/org"
|
||||
@@ -124,7 +124,7 @@ tests:
|
||||
runner:
|
||||
mode: "dind"
|
||||
dind:
|
||||
copyExternals: false
|
||||
copyRunnerExternals: false
|
||||
release:
|
||||
name: "test-name"
|
||||
namespace: "test-namespace"
|
||||
|
||||
@@ -189,7 +189,7 @@ runner:
|
||||
# assets from the /home/runner/externals directory, copy externals
|
||||
# starts the init container whose purpose is to prepare the environment
|
||||
# for the dind container.
|
||||
copyExternals: true
|
||||
copyRunnerExternals: true
|
||||
dockerGroupId: "123"
|
||||
dockerSock: "unix:///var/run/docker.sock"
|
||||
waitForDockerInSeconds: 120
|
||||
|
||||
Reference in New Issue
Block a user