-
Notifications
You must be signed in to change notification settings - Fork 178
1058 lines (1027 loc) · 46.6 KB
/
acceptance-tests-runner.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
name: 'Acceptance Tests Execution'
run-name: 'Acceptance Tests Execution ${{ inputs.test_group }}'
# Called by acceptance-tests.yml workflow to run acceptance tests. Input and secret variables are defined by the caller depending if `dev` or `qa` cloud env is used.
on:
workflow_call:
inputs:
terraform_version:
description: 'Terraform version to use, e.g. 1.6.x'
type: string
required: true
provider_version:
description: 'Previous MongoDB Atlas Provider version to use in Migration tests, e.g. 1.14.0, empty for latest'
type: string
required: false
test_group:
description: 'Test group to run, e.g. advanced_cluster, empty for all'
type: string
required: false
test_name:
description: 'Name of the test to run, e.g. TestAccNetworkRSNetworkPeering_basicAzure, empty for all (this is regex & requires Test group to be specified as well)'
type: string
required: false
ref:
description: 'The branch, tag or SHA where tests will run, e.g. v1.14.0, empty for default branch'
type: string
required: false
mongodb_atlas_org_id:
type: string
required: true
mongodb_atlas_base_url:
type: string
required: true
mongodb_atlas_project_owner_id:
type: string
required: true
mongodb_atlas_teams_ids:
type: string
required: true
azure_atlas_app_id:
type: string
required: true
azure_service_principal_id:
type: string
required: true
azure_tenant_id:
type: string
required: true
aws_secret_name:
type: string
required: true
aws_region_federation:
type: string
required: true
mongodb_atlas_federation_settings_id:
type: string
required: true
mongodb_atlas_federated_okta_idp_id:
type: string
required: true
mongodb_atlas_federated_idp_id:
type: string
required: true
mongodb_atlas_federated_sso_url:
type: string
required: true
mongodb_atlas_federated_issuer_uri:
type: string
required: true
mongodb_atlas_federated_org_id:
type: string
required: true
mongodb_atlas_gov_org_id:
type: string
required: true
mongodb_atlas_gov_base_url:
type: string
required: true
mongodb_atlas_rp_org_id:
type: string
required: true
mongodb_atlas_gov_project_owner_id:
type: string
required: true
mongodb_atlas_federated_settings_associated_domain:
type: string
required: true
mongodb_atlas_project_ear_pe_id:
type: string
required: true
mongodb_atlas_enable_preview:
type: string
required: true
azure_private_endpoint_region:
type: string
required: true
mongodb_atlas_flex_project_id:
type: string
required: true
secrets: # all secrets are passed explicitly in this workflow
mongodb_atlas_public_key:
required: true
mongodb_atlas_private_key:
required: true
ca_cert:
required: true
aws_account_id:
required: true
aws_access_key_id:
required: true
aws_secret_access_key:
required: true
aws_s3_bucket_federation:
required: true
aws_s3_bucket_backup:
required: true
azure_service_url_backup:
required: true
azure_blob_storage_container_backup:
required: true
mongodb_atlas_ldap_hostname:
required: true
mongodb_atlas_ldap_username:
required: true
mongodb_atlas_ldap_password:
required: true
mongodb_atlas_ldap_port:
required: true
mongodb_atlas_ldap_ca_certificate:
required: true
mongodb_atlas_private_endpoint_id:
required: true
mongodb_atlas_private_endpoint_dns_name:
required: true
mongodb_atlas_gov_private_key:
required: true
mongodb_atlas_gov_public_key:
required: true
mongodb_atlas_rp_private_key:
required: true
mongodb_atlas_rp_public_key:
required: true
azure_directory_id:
required: true
azure_resource_group_name:
required: true
azure_subscription_id:
required: true
azure_vnet_name:
required: true
azure_vnet_name_updated:
required: true
azure_client_id:
required: true
azure_key_vault_name:
required: true
azure_key_identifier:
required: true
azure_key_vault_name_updated:
required: true
azure_key_identifier_updated:
required: true
azure_app_secret:
required: true
env:
TF_ACC: 1
TF_LOG: ${{ vars.LOG_LEVEL }}
ACCTEST_TIMEOUT: ${{ vars.ACCTEST_TIMEOUT }}
# Only Migration tests are run when a specific previous provider version is set
# If the name (regex) of the test is set, only that test is run
ACCTEST_REGEX_RUN: ${{ inputs.test_name || inputs.provider_version == '' && '^Test(Acc|Mig)' || '^TestMig' }}
MONGODB_ATLAS_BASE_URL: ${{ inputs.mongodb_atlas_base_url }}
MONGODB_ATLAS_ORG_ID: ${{ inputs.mongodb_atlas_org_id }}
MONGODB_ATLAS_PUBLIC_KEY: ${{ secrets.mongodb_atlas_public_key }}
MONGODB_ATLAS_PRIVATE_KEY: ${{ secrets.mongodb_atlas_private_key }}
MONGODB_ATLAS_GOV_PUBLIC_KEY: ${{ secrets.mongodb_atlas_gov_public_key }}
MONGODB_ATLAS_GOV_PRIVATE_KEY: ${{ secrets.mongodb_atlas_gov_private_key }}
MONGODB_ATLAS_GOV_BASE_URL: ${{ inputs.mongodb_atlas_gov_base_url }}
MONGODB_ATLAS_GOV_ORG_ID: ${{ inputs.mongodb_atlas_gov_org_id }}
jobs:
get-provider-version:
runs-on: ubuntu-latest
permissions: {}
outputs:
provider_version: ${{ inputs.provider_version || steps.get_last_release.outputs.last_provider_version }}
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- name: Get Last Release
id: get_last_release
shell: bash
run: |
LAST_RELEASE=$(curl -sSfL -X GET https://api.github.com/repos/mongodb/terraform-provider-mongodbatlas/releases/latest | jq -r '.tag_name | ltrimstr("v")')
echo "Last release: $LAST_RELEASE"
echo "last_provider_version=${LAST_RELEASE}" >> "${GITHUB_OUTPUT}"
change-detection:
runs-on: ubuntu-latest
permissions: {}
env:
mustTrigger: ${{ github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && inputs.test_group == '' ) }}
outputs: # ensure resources are sorted alphabetically
advanced_cluster: ${{ steps.filter.outputs.advanced_cluster == 'true' || env.mustTrigger == 'true' }}
advanced_cluster_tpf: ${{ steps.filter.outputs.advanced_cluster_tpf == 'true' || env.mustTrigger == 'true' }}
assume_role: ${{ steps.filter.outputs.assume_role == 'true' || env.mustTrigger == 'true' }}
backup: ${{ steps.filter.outputs.backup == 'true' || env.mustTrigger == 'true' }}
control_plane_ip_addresses: ${{ steps.filter.outputs.control_plane_ip_addresses == 'true' || env.mustTrigger == 'true' }}
cluster: ${{ steps.filter.outputs.cluster == 'true' || env.mustTrigger == 'true' }}
cluster_outage_simulation: ${{ steps.filter.outputs.cluster_outage_simulation == 'true' || env.mustTrigger == 'true' }}
config: ${{ steps.filter.outputs.config == 'true' || env.mustTrigger == 'true' }}
encryption: ${{ steps.filter.outputs.encryption == 'true' || env.mustTrigger == 'true' }}
event_trigger: ${{ steps.filter.outputs.event_trigger == 'true' || env.mustTrigger == 'true' }}
federated: ${{ steps.filter.outputs.federated == 'true' || env.mustTrigger == 'true' }}
flex_cluster: ${{ steps.filter.outputs.flex_cluster == 'true' || env.mustTrigger == 'true' }}
generic: ${{ steps.filter.outputs.generic == 'true' || env.mustTrigger == 'true' }}
global_cluster_config: ${{ steps.filter.outputs.global_cluster_config == 'true' || env.mustTrigger == 'true' }}
ldap: ${{ steps.filter.outputs.ldap == 'true' || env.mustTrigger == 'true' }}
mongodb_employee_access_grant: ${{ steps.filter.outputs.mongodb_employee_access_grant == 'true' || env.mustTrigger == 'true' }}
network: ${{ steps.filter.outputs.network == 'true' || env.mustTrigger == 'true' }}
project: ${{ steps.filter.outputs.project == 'true' || env.mustTrigger == 'true' }}
push_based_log_export: ${{ steps.filter.outputs.push_based_log_export == 'true' || env.mustTrigger == 'true' }}
resource_policy: ${{ steps.filter.outputs.resource_policy == 'true' || env.mustTrigger == 'true' }}
search_deployment: ${{ steps.filter.outputs.search_deployment == 'true' || env.mustTrigger == 'true' }}
search_index: ${{ steps.filter.outputs.search_index == 'true' || env.mustTrigger == 'true' }}
serverless: ${{ steps.filter.outputs.serverless == 'true' || env.mustTrigger == 'true' }}
stream: ${{ steps.filter.outputs.stream == 'true' || env.mustTrigger == 'true' }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36
id: filter
if: ${{ inputs.test_group == '' && env.mustTrigger == 'false' }}
with:
filters: |
advanced_cluster:
- 'internal/service/advancedcluster/!(*_test).go' # matches any adv_cluster file change except test files
advanced_cluster_tpf:
- 'internal/service/advancedclustertpf/*.go'
- 'internal/service/advancedcluster/*_test.go'
assume_role:
- 'internal/provider/*.go'
backup:
- 'internal/service/cloudbackupschedule/*.go'
- 'internal/service/cloudbackupsnapshot/*.go'
- 'internal/service/cloudbackupsnapshotexportbucket/*.go'
- 'internal/service/cloudbackupsnapshotexportjob/*.go'
- 'internal/service/cloudbackupsnapshotrestorejob/*.go'
- 'internal/service/onlinearchive/*.go'
control_plane_ip_addresses:
- 'internal/service/controlplaneipaddresses/*.go'
cluster:
- 'internal/service/cluster/*.go'
cluster_outage_simulation:
- 'internal/service/clusteroutagesimulation/*.go'
config:
- 'internal/service/alertconfiguration/*.go'
- 'internal/service/apikey/*.go'
- 'internal/service/atlasuser/*.go'
- 'internal/service/cloudprovideraccess/*.go'
- 'internal/service/customdbrole/*.go'
- 'internal/service/customdnsconfigurationclusteraws/*.go'
- 'internal/service/databaseuser/*.go'
- 'internal/service/maintenancewindow/*.go'
- 'internal/service/organization/*.go'
- 'internal/service/orginvitation/*.go'
- 'internal/service/projectapikey/*.go'
- 'internal/service/rolesorgid/*.go'
- 'internal/service/team/*.go'
- 'internal/service/thirdpartyintegration/*.go'
encryption:
- 'internal/service/encryptionatrest/*.go'
- 'internal/service/encryptionatrestprivateendpoint/*.go'
event_trigger:
- 'internal/service/eventtrigger/*.go'
federated:
- 'internal/service/federateddatabaseinstance/*.go'
- 'internal/service/federatedquerylimit/*.go'
- 'internal/service/federatedsettingsidentityprovider/*.go'
- 'internal/service/federatedsettingsorgconfig/*.go'
- 'internal/service/federatedsettingsorgrolemapping/*.go'
flex_cluster:
- 'internal/service/flexcluster/*.go'
generic:
- 'internal/service/auditing/*.go'
- 'internal/service/backupcompliancepolicy/*.go'
- 'internal/service/x509authenticationdatabaseuser/*.go'
global_cluster_config:
- 'internal/service/globalclusterconfig/*.go'
ldap:
- 'internal/service/ldapconfiguration/*.go'
- 'internal/service/ldapverify/*.go'
mongodb_employee_access_grant:
- 'internal/service/mongodbemployeeaccessgrant/*.go'
network:
- 'internal/service/networkcontainer/*.go'
- 'internal/service/networkpeering/*.go'
- 'internal/service/privateendpointregionalmode/*.go'
- 'internal/service/privatelinkendpoint/*.go'
- 'internal/service/privatelinkendpointservice/*.go'
- 'internal/service/privatelinkendpointservicedatafederationonlinearchive/*.go'
project:
- 'internal/service/accesslistapikey/*.go'
- 'internal/service/project/*.go'
- 'internal/service/projectinvitation/*.go'
- 'internal/service/projectipaccesslist/*.go'
- 'internal/service/projectipaddresses/*.go'
push_based_log_export:
- 'internal/service/pushbasedlogexport/*.go'
resource_policy:
- 'internal/service/resourcepolicy/*.go'
search_deployment:
- 'internal/service/searchdeployment/*.go'
search_index:
- 'internal/service/searchindex/*.go'
serverless:
- 'internal/service/privatelinkendpointserverless/*.go'
- 'internal/service/privatelinkendpointserviceserverless/*.go'
- 'internal/service/serverlessinstance/*.go'
stream:
- 'internal/service/streamconnection/*.go'
- 'internal/service/streaminstance/*.go'
- 'internal/service/streamprocessor/*.go'
advanced_cluster:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.advanced_cluster == 'true' || inputs.test_group == 'advanced_cluster' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/advancedcluster
run: make testacc
advanced_cluster_tpf:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.advanced_cluster_tpf == 'true' || inputs.test_group == 'advanced_cluster_tpf' }}
env:
MONGODB_ATLAS_ADVANCED_CLUSTER_V2_SCHEMA: 'true'
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Prepare new advanced_cluster
run: make tools enable-advancedclustertpf
- name: Unit tests # delete after allowAdvancedClusterV2Schema is removed
run: go test -v ./internal/testutil/acc/advanced_cluster_schema_v2_test.go
- name: Mocked Acceptance Tests
env:
ACCTEST_REGEX_RUN: '^TestAccMockable'
ACCTEST_PACKAGES: ./internal/service/advancedclustertpf
MONGODB_ATLAS_PROJECT_ID: '111111111111111111111111' # 24 chars used for skipping acc.ProjectIDExecution(t) in mocked tests
HTTP_MOCKER_REPLAY: 'true'
run: make testacc
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
HTTP_MOCKER_CAPTURE: 'true'
ACCTEST_PACKAGES: |
./internal/service/advancedcluster
./internal/service/advancedclustertpf
run: make testacc
advanced_cluster_tpf_move:
needs: [ change-detection, get-provider-version ]
if: ${{ (needs.change-detection.outputs.advanced_cluster_tpf == 'true' || inputs.test_group == 'advanced_cluster_tpf') && inputs.terraform_version == '1.10.x' }}
env:
MONGODB_ATLAS_ADVANCED_CLUSTER_V2_SCHEMA: 'true'
strategy:
max-parallel: 2
fail-fast: false
matrix:
terraform_version: ['1.8.x', '1.9.x'] # TF supported versions for MoveState apart from latest one, 1.10.x
name: advanced_cluster_tpf_move-${{ matrix.terraform_version }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ matrix.terraform_version }}
terraform_wrapper: false
- name: Prepare new advanced_cluster
run: make tools enable-advancedclustertpf
- name: Acceptance Tests
env:
ACCTEST_REGEX_RUN: '^TestAccAdvancedCluster_move'
ACCTEST_PACKAGES: ./internal/service/advancedclustertpf
run: make testacc
assume_role:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.assume_role == 'true' || inputs.test_group == 'assume_role' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- id: sts-assume-role
name: Generate STS Temporary credential for acceptance testing
shell: bash
env:
AWS_REGION: ${{ vars.AWS_REGION }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
ASSUME_ROLE_ARN: ${{ vars.ASSUME_ROLE_ARN }}
run: bash ./scripts/generate-credentials-with-sts-assume-role.sh
- name: Acceptance Tests
env:
MONGODB_ATLAS_PUBLIC_KEY: ""
MONGODB_ATLAS_PRIVATE_KEY: ""
ASSUME_ROLE_ARN: ${{ vars.ASSUME_ROLE_ARN }}
AWS_REGION: ${{ vars.AWS_REGION }}
STS_ENDPOINT: ${{ vars.STS_ENDPOINT }}
SECRET_NAME: ${{ inputs.aws_secret_name }}
AWS_ACCESS_KEY_ID: ${{ steps.sts-assume-role.outputs.aws_access_key_id }}
AWS_SECRET_ACCESS_KEY: ${{ steps.sts-assume-role.outputs.aws_secret_access_key }}
AWS_SESSION_TOKEN: ${{ steps.sts-assume-role.outputs.AWS_SESSION_TOKEN }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/provider
run: make testacc
backup:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.backup == 'true' || inputs.test_group == 'backup' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_PROJECT_OWNER_ID: ${{ inputs.mongodb_atlas_project_owner_id }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
AWS_REGION: ${{ vars.AWS_REGION_LOWERCASE }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
AWS_S3_BUCKET: ${{ secrets.aws_s3_bucket_backup }}
AZURE_BLOB_STORAGE_CONTAINER_NAME: ${{ secrets.azure_blob_storage_container_backup }}
AZURE_SERVICE_URL: ${{ secrets.azure_service_url_backup }}
AZURE_ATLAS_APP_ID: ${{ inputs.azure_atlas_app_id }}
AZURE_SERVICE_PRINCIPAL_ID: ${{ inputs.azure_service_principal_id }}
AZURE_TENANT_ID: ${{ inputs.azure_tenant_id }}
ACCTEST_PACKAGES: |
./internal/service/cloudbackupschedule
./internal/service/cloudbackupsnapshot
./internal/service/cloudbackupsnapshotexportbucket
./internal/service/cloudbackupsnapshotexportjob
./internal/service/cloudbackupsnapshotrestorejob
./internal/service/onlinearchive
run: make testacc
control_plane_ip_addresses:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.control_plane_ip_addresses == 'true' || inputs.test_group == 'control_plane_ip_addresses' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/controlplaneipaddresses
run: make testacc
cluster:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.cluster == 'true' || inputs.test_group == 'cluster' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/cluster
run: make testacc
cluster_outage_simulation:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.cluster_outage_simulation == 'true' || inputs.test_group == 'cluster_outage_simulation' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/clusteroutagesimulation
run: make testacc
config:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.config == 'true' || inputs.test_group == 'config' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_PROJECT_OWNER_ID: ${{ inputs.mongodb_atlas_project_owner_id }}
MONGODB_ATLAS_USERNAME: ${{ vars.MONGODB_ATLAS_USERNAME }}
MONGODB_ATLAS_USERNAME_2: ${{ vars.MONGODB_ATLAS_USERNAME_2 }}
AZURE_ATLAS_APP_ID: ${{ inputs.azure_atlas_app_id }}
AZURE_SERVICE_PRINCIPAL_ID: ${{ inputs.azure_service_principal_id }}
AZURE_TENANT_ID: ${{ inputs.azure_tenant_id }}
AWS_REGION: ${{ vars.AWS_REGION_LOWERCASE }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
AWS_S3_BUCKET: ${{ secrets.aws_s3_bucket_federation }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/alertconfiguration
./internal/service/atlasuser
./internal/service/cloudprovideraccess
./internal/service/customdbrole
./internal/service/customdnsconfigurationclusteraws
./internal/service/databaseuser
./internal/service/maintenancewindow
./internal/service/organization
./internal/service/orginvitation
./internal/service/projectapikey
./internal/service/apikey
./internal/service/rolesorgid
./internal/service/team
./internal/service/thirdpartyintegration
run: make testacc
encryption:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.encryption == 'true' || inputs.test_group == 'encryption' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/encryptionatrest
./internal/service/encryptionatrestprivateendpoint
MONGODB_ATLAS_PROJECT_EAR_PE_ID: ${{ inputs.mongodb_atlas_project_ear_pe_id }}
AZURE_PRIVATE_ENDPOINT_REGION: ${{ inputs.azure_private_endpoint_region }}
AZURE_CLIENT_ID: ${{ secrets.azure_client_id }}
AZURE_RESOURCE_GROUP_NAME: ${{ secrets.azure_resource_group_name }}
AZURE_SUBSCRIPTION_ID: ${{ secrets.azure_subscription_id }}
AZURE_TENANT_ID: ${{ vars.azure_tenant_id }}
AZURE_APP_SECRET: ${{ secrets.azure_app_secret }}
AZURE_KEY_VAULT_NAME: ${{ secrets.azure_key_vault_name }}
AZURE_KEY_IDENTIFIER: ${{ secrets.azure_key_identifier }}
AZURE_KEY_VAULT_NAME_UPDATED: ${{ secrets.azure_key_vault_name_updated }}
AZURE_KEY_IDENTIFIER_UPDATED: ${{ secrets.azure_key_identifier_updated }}
MONGODB_ATLAS_ENABLE_PREVIEW: ${{ inputs.mongodb_atlas_enable_preview }}
run: make testacc
event_trigger:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.event_trigger == 'true' || inputs.test_group == 'event_trigger' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/eventtrigger
run: make testacc
federated:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.federated == 'true' || inputs.test_group == 'federated' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_FEDERATION_SETTINGS_ID: ${{ inputs.mongodb_atlas_federation_settings_id }}
MONGODB_ATLAS_FEDERATED_OKTA_IDP_ID: ${{ inputs.mongodb_atlas_federated_okta_idp_id }}
MONGODB_ATLAS_FEDERATED_IDP_ID: ${{ inputs.mongodb_atlas_federated_idp_id }}
MONGODB_ATLAS_FEDERATED_SSO_URL: ${{ inputs.mongodb_atlas_federated_sso_url }}
MONGODB_ATLAS_FEDERATED_ISSUER_URI: ${{ inputs.mongodb_atlas_federated_issuer_uri }}
MONGODB_ATLAS_FEDERATED_ORG_ID: ${{ inputs.mongodb_atlas_federated_org_id }}
MONGODB_ATLAS_FEDERATED_SETTINGS_ASSOCIATED_DOMAIN: ${{ inputs.mongodb_atlas_federated_settings_associated_domain }}
AWS_S3_BUCKET: ${{ secrets.aws_s3_bucket_federation }}
AWS_REGION: ${{ vars.aws_region_federation }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/federateddatabaseinstance
./internal/service/federatedquerylimit
./internal/service/federatedsettingsidentityprovider
./internal/service/federatedsettingsorgconfig
./internal/service/federatedsettingsorgrolemapping
run: make testacc
flex_cluster:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.flex_cluster == 'true' || inputs.test_group == 'flex_cluster' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
MONGODB_ATLAS_FLEX_PROJECT_ID: ${{ inputs.mongodb_atlas_flex_project_id }}
MONGODB_ATLAS_ENABLE_PREVIEW: "true"
ACCTEST_PACKAGES: ./internal/service/flexcluster
run: make testacc
generic:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.generic == 'true' || inputs.test_group == 'generic' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_PROJECT_OWNER_ID: ${{ inputs.mongodb_atlas_project_owner_id }}
CA_CERT: ${{ secrets.ca_cert }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/auditing
./internal/service/backupcompliancepolicy
./internal/service/x509authenticationdatabaseuser
run: make testacc
global_cluster_config:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.global_cluster_config == 'true' || inputs.test_group == 'global_cluster_config' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/globalclusterconfig
run: make testacc
ldap:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.ldap == 'true' || inputs.test_group == 'ldap' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LDAP_HOSTNAME: ${{ secrets.mongodb_atlas_ldap_hostname }}
MONGODB_ATLAS_LDAP_USERNAME: ${{ secrets.mongodb_atlas_ldap_username }}
MONGODB_ATLAS_LDAP_PASSWORD: ${{ secrets.mongodb_atlas_ldap_password }}
MONGODB_ATLAS_LDAP_PORT: ${{ secrets.mongodb_atlas_ldap_port }}
MONGODB_ATLAS_LDAP_CA_CERTIFICATE: ${{ secrets.mongodb_atlas_ldap_ca_certificate }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/ldapconfiguration
./internal/service/ldapverify
run: make testacc
mongodb_employee_access_grant:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.mongodb_employee_access_grant == 'true' || inputs.test_group == 'mongodb_employee_access_grant' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/mongodbemployeeaccessgrant
run: make testacc
network:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.network == 'true' || inputs.test_group == 'network' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_PRIVATE_ENDPOINT_ID: ${{ secrets.mongodb_atlas_private_endpoint_id }}
MONGODB_ATLAS_PRIVATE_ENDPOINT_DNS_NAME: ${{ secrets.mongodb_atlas_private_endpoint_dns_name }}
AWS_ACCOUNT_ID: ${{ secrets.aws_account_id }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
AWS_REGION: ${{ vars.AWS_REGION }}
AWS_REGION_UPPERCASE: ${{ vars.AWS_REGION_UPPERCASE }}
AWS_REGION_LOWERCASE: ${{ vars.AWS_REGION_LOWERCASE }}
AWS_SECURITY_GROUP_1: ${{ vars.AWS_SECURITY_GROUP_1 }}
AWS_SECURITY_GROUP_2: ${{ vars.AWS_SECURITY_GROUP_2 }}
AWS_VPC_CIDR_BLOCK: ${{ vars.AWS_VPC_CIDR_BLOCK }}
AWS_VPC_ID: ${{ vars.AWS_VPC_ID }}
AZURE_DIRECTORY_ID: ${{ secrets.azure_directory_id }}
AZURE_RESOURCE_GROUP_NAME: ${{ secrets.azure_resource_group_name }}
AZURE_SUBSCRIPTION_ID: ${{ secrets.azure_subscription_id }}
AZURE_VNET_NAME: ${{ secrets.azure_vnet_name }}
AZURE_VNET_NAME_UPDATED: ${{ secrets.azure_vnet_name_updated }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/networkcontainer
./internal/service/networkpeering
./internal/service/privateendpointregionalmode
./internal/service/privatelinkendpoint
./internal/service/privatelinkendpointservice
./internal/service/privatelinkendpointservicedatafederationonlinearchive
run: make testacc
project:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.project == 'true' || inputs.test_group == 'project' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_PROJECT_OWNER_ID: ${{ inputs.mongodb_atlas_project_owner_id }}
MONGODB_ATLAS_GOV_PROJECT_OWNER_ID: ${{ inputs.mongodb_atlas_gov_project_owner_id }}
MONGODB_ATLAS_TEAMS_IDS: ${{ inputs.mongodb_atlas_teams_ids }}
AWS_ACCOUNT_ID: ${{ secrets.aws_account_id }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
AWS_REGION: ${{ vars.AWS_REGION }}
AWS_SECURITY_GROUP_1: ${{ vars.AWS_SECURITY_GROUP_1 }}
AWS_SECURITY_GROUP_2: ${{ vars.AWS_SECURITY_GROUP_2 }}
AWS_VPC_CIDR_BLOCK: ${{ vars.AWS_VPC_CIDR_BLOCK }}
AWS_VPC_ID: ${{ vars.AWS_VPC_ID }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: |
./internal/service/accesslistapikey
./internal/service/project
./internal/service/projectinvitation
./internal/service/projectipaccesslist
./internal/service/projectipaddresses
run: make testacc
push_based_log_export:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.push_based_log_export == 'true' || inputs.test_group == 'push_based_log_export' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
AWS_REGION: ${{ vars.AWS_REGION_LOWERCASE }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.aws_secret_access_key }}
AWS_ACCESS_KEY_ID: ${{ secrets.aws_access_key_id }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/pushbasedlogexport
run: make testacc
resource_policy:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.resource_policy == 'true' || inputs.test_group == 'resource_policy' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_ORG_ID: ${{ inputs.mongodb_atlas_rp_org_id }}
MONGODB_ATLAS_PUBLIC_KEY: ${{ secrets.mongodb_atlas_rp_public_key }}
MONGODB_ATLAS_PRIVATE_KEY: ${{ secrets.mongodb_atlas_rp_private_key }}
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
MONGODB_ATLAS_ENABLE_PREVIEW: "true"
ACCTEST_PACKAGES: |
./internal/service/resourcepolicy
run: make testacc
search_deployment:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.search_deployment == 'true' || inputs.test_group == 'search_deployment' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with:
terraform_version: ${{ inputs.terraform_version }}
terraform_wrapper: false
- name: Acceptance Tests
env:
MONGODB_ATLAS_LAST_VERSION: ${{ needs.get-provider-version.outputs.provider_version }}
ACCTEST_PACKAGES: ./internal/service/searchdeployment
run: make testacc
search_index:
needs: [ change-detection, get-provider-version ]
if: ${{ needs.change-detection.outputs.search_index == 'true' || inputs.test_group == 'search_index' }}
runs-on: ubuntu-latest
permissions: {}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
ref: ${{ inputs.ref || github.ref }}
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a
with:
go-version-file: 'go.mod'
- uses: hashicorp/setup-terraform@b9cd54a3c349d3f38e8881555d616ced269862dd
with: