Skip to content

Commit a8cb7ca

Browse files
authored
Add service account for test pod (#299)
1 parent e9fa125 commit a8cb7ca

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

scripts/deploy-test-pods.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ fi
1919

2020
# shellcheck disable=SC2002 # Useless cat.
2121
cat ./test-target/local-pod-under-test.yaml | APP="testdp" RESOURCE_TYPE="Deployment" MULTUS_ANNOTATION=$MULTUS_ANNOTATION REPLICAS=$REPLICAS "$SCRIPT_DIR"/mo > ./temp/rendered-local-pod-under-test-template.yaml
22+
oc apply --filename ./test-target/test-service-account.yaml
2223
oc apply --filename ./temp/rendered-local-pod-under-test-template.yaml
2324
rm ./temp/rendered-local-pod-under-test-template.yaml
2425

test-target/local-pod-under-test.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ spec:
2525
spec:
2626
terminationGracePeriodSeconds: 30
2727
automountServiceAccountToken: false
28+
serviceAccountName: test-pod-sa
2829
containers:
2930
- image: quay.io/testnetworkfunction/cnf-test-partner:latest
3031
imagePullPolicy: IfNotPresent
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
apiVersion: v1
3+
kind: ServiceAccount
4+
metadata:
5+
name: test-pod-sa
6+
namespace: tnf

0 commit comments

Comments
 (0)