@@ -17,74 +17,77 @@ concurrency:
17
17
18
18
jobs :
19
19
https_trigger :
20
- if : ${{ github.event_name == 'push' || github.repository == github.event.pull_request.head.repo.full_name && github.actor != 'dependabot[bot]' }}
20
+ timeout-minutes : 10
21
21
permissions :
22
22
contents : ' read'
23
23
id-token : ' write'
24
24
runs-on : ' ubuntu-latest'
25
25
steps :
26
- - uses : ' actions/checkout@v4'
26
+ - uses : ' actions/checkout@v4'
27
27
28
- - uses : ' actions/setup-node@v4'
29
- with :
30
- node-version : ' 20.x'
28
+ - uses : ' actions/setup-node@v4'
29
+ with :
30
+ node-version : ' 20.x'
31
31
32
- - name : ' npm build'
33
- run : ' npm ci && npm run build'
32
+ - name : ' npm build'
33
+ run : ' npm ci && npm run build'
34
34
35
- - uses : ' google-github-actions/auth@v2'
36
- with :
37
- workload_identity_provider : ' ${{ vars.WIF_PROVIDER_NAME }}'
38
- service_account : ' ${{ vars.SERVICE_ACCOUNT_EMAIL }}'
35
+ - uses : ' google-github-actions/auth@v2'
36
+ with :
37
+ project_id : ' ${{ vars.PROJECT_ID }}'
38
+ workload_identity_provider : ' ${{ vars.WIF_PROVIDER_NAME }}'
39
39
40
- - id : ' deploy'
41
- uses : ' ./'
42
- with :
43
- name : ' https-trigger-${{ github.run_number }}'
44
- runtime : ' nodejs16 '
45
- entry_point : ' helloWorld'
46
- source_dir : ' ./tests/test-node-func/'
47
- https_trigger_security_level : ' secure_always '
40
+ - id : ' deploy'
41
+ uses : ' ./'
42
+ with :
43
+ name : ' https-trigger-${{ github.run_number }}'
44
+ runtime : ' nodejs22 '
45
+ entry_point : ' helloWorld'
46
+ source_dir : ' ./tests/test-node-func/'
47
+ service_account : ' ${{ vars.SERVICE_ACCOUNT_EMAIL }} '
48
48
49
49
event_trigger :
50
- if : ${{ github.event_name == 'push' || github.repository == github.event.pull_request.head.repo.full_name && github.actor != 'dependabot[bot]' }}
50
+ timeout-minutes : 10
51
51
permissions :
52
52
contents : ' read'
53
53
id-token : ' write'
54
54
runs-on : ' ubuntu-latest'
55
55
steps :
56
- - uses : ' actions/checkout@v4'
56
+ - uses : ' actions/checkout@v4'
57
57
58
- - uses : ' actions/setup-node@v4'
59
- with :
60
- node-version : ' 20.x'
58
+ - uses : ' actions/setup-node@v4'
59
+ with :
60
+ node-version : ' 20.x'
61
61
62
- - name : ' npm build'
63
- run : ' npm ci && npm run build'
62
+ - name : ' npm build'
63
+ run : ' npm ci && npm run build'
64
64
65
- - uses : ' google-github-actions/auth@v2'
66
- with :
67
- workload_identity_provider : ' ${{ vars.WIF_PROVIDER_NAME }}'
68
- service_account : ' ${{ vars.SERVICE_ACCOUNT_EMAIL }}'
65
+ - uses : ' google-github-actions/auth@v2'
66
+ with :
67
+ project_id : ' ${{ vars.PROJECT_ID }}'
68
+ workload_identity_provider : ' ${{ vars.WIF_PROVIDER_NAME }}'
69
69
70
- - id : ' deploy'
71
- uses : ' ./'
72
- with :
73
- name : ' event-trigger-${{ github.run_number }}'
74
- runtime : ' nodejs16'
75
- entry_point : ' helloWorld'
76
- source_dir : ' ./tests/test-node-func/'
77
- event_trigger_type : ' providers/cloud.pubsub/eventTypes/topic.publish'
78
- event_trigger_resource : ' ${{ vars.PUBSUB_TOPIC_NAME }}'
79
- event_trigger_retry : true
80
- env_vars_file : ' ./tests/env-var-files/test.good.yaml'
81
- build_environment_variables : ' FOO=bar, ZIP=zap'
82
- build_environment_variables_file : ' ./tests/env-var-files/test.good.yaml'
83
- secret_environment_variables : |-
84
- FOO=${{ vars.SECRET_VERSION_NAME }}
85
- BAR=${{ vars.SECRET_NAME }}
86
- secret_volumes : ' /etc/secrets/foo=${{ vars.SECRET_VERSION_NAME }}'
87
- service_account_email : ' ${{ vars.SERVICE_ACCOUNT_EMAIL }}'
88
- min_instances : 2
89
- max_instances : 5
90
- timeout : 300
70
+ - id : ' deploy'
71
+ uses : ' ./'
72
+ with :
73
+ name : ' event-trigger-${{ github.run_number }}'
74
+ runtime : ' nodejs22'
75
+ entry_point : ' helloWorld'
76
+ source_dir : ' ./tests/test-node-func/'
77
+ event_trigger_type : ' google.cloud.pubsub.topic.v1.messagePublished'
78
+ event_trigger_pubsub_topic : ' ${{ vars.PUBSUB_TOPIC_NAME }}'
79
+ event_trigger_retry : true
80
+ event_trigger_service_account : ' ${{ vars.SERVICE_ACCOUNT_EMAIL }}'
81
+ environment_variables : |-
82
+ FOO=bar
83
+ ZIP=zap
84
+ build_environment_variables : |-
85
+ FRUIT=apple
86
+ MEAT=bacon
87
+ secrets : |-
88
+ SECRET_FOO=${{ vars.SECRET_VERSION_NAME }}
89
+ SECRET_BAR=${{ vars.SECRET_NAME }}
90
+ /etc/secrets/foo=${{ vars.SECRET_VERSION_NAME }}
91
+ service_account : ' ${{ vars.SERVICE_ACCOUNT_EMAIL }}'
92
+ min_instance_count : 2
93
+ max_instance_count : 5
0 commit comments