Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prepare 2.10.0 release #136

Merged
merged 123 commits into from
Feb 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
123 commits
Select commit Hold shift + click to select a range
8fd56bd
prepare release (#80) (#188)
sloloris Jan 20, 2022
aea6005
Do not allow 0% segment rule weights (#189)
ldhenry Jan 21, 2022
f1e972c
Fix flag trigger creation panic (#190)
ldhenry Jan 21, 2022
09a6fa3
Backmerge/release 2.4.1 (#191)
ldhenry Jan 21, 2022
e493b76
Add Slack webhooks to audit_log_subscription (#192)
ldhenry Feb 7, 2022
2512cf3
backmerge v2.5.0 (#193)
ldhenry Feb 8, 2022
f4332bc
Use jennifer to generate audit log subscription configs (#194)
ldhenry Feb 8, 2022
de0fe41
Run terraform provider acceptance tests daily and notify of failures …
ldhenry Feb 8, 2022
9a38dde
Update changelog branch (#195)
ldhenry Feb 9, 2022
d285706
[ sc-143291] update autogenerated audit_log_subscription configs (#197)
monsagri Mar 14, 2022
42d99ac
Increase checkpoint-api.harhicorp.com timeout to 10s (#198)
ldhenry Mar 17, 2022
04b73ff
Updated destination tests to use random env keys to avoid env conflic…
ctawiah Apr 6, 2022
b6bc3f2
Merge pull request #199 from launchdarkly/ctawiah/sc-148136/randomize…
ctawiah Apr 6, 2022
e722f06
[sc 148065] add approvals bypass to terraform docs (#200)
monsagri Apr 7, 2022
b88452a
Backmerge/release 2.6.0 (#201)
monsagri Apr 7, 2022
ae41bdb
fix doc issues (#202)
sloloris Apr 14, 2022
a402d11
[sc-149869] roll back documentation changes regarding (#203)
monsagri Apr 14, 2022
66d55a1
backmerge 2.6.1 (#204)
monsagri Apr 14, 2022
494df8f
Imiller/sc 151834/add base permissions to custom role resource (#205)
sloloris May 4, 2022
38d70bc
Backmerge/release 2.7.0 (#206)
sloloris May 5, 2022
6559f71
(bug-fix) Update modules to accept new API header
May 11, 2022
4795ea3
Merge pull request #207 from launchdarkly/fix-ci
lucywyman May 13, 2022
626aaae
Update circleci test timeout to 15 seconds
May 19, 2022
2c88570
Merge pull request #208 from launchdarkly/sunny/sc-153482/increase-ti…
lucywyman May 20, 2022
9084524
Regenerate auditlog configs to resolve CI failures (#211)
ldhenry Jun 30, 2022
54dbc29
Run make generate to supress CI failures (#212)
ldhenry Jul 11, 2022
b9a3419
added a check for environment and warning
Jul 12, 2022
c073a3b
fix go lint error
Jul 12, 2022
822f9d8
Merge branch 'main' into sunny/sc-158595/leftover-resources-cannot-be…
Jul 12, 2022
2ba884b
use environmentExists function
Jul 12, 2022
dd21dac
remove grafana
Jul 13, 2022
66c862c
fix: [sc-158595] leftover resources cannot be cleared out after launc…
Jul 13, 2022
88840f0
Update changelog with bug fix for datasource feature flag environment
Jul 13, 2022
33a1f9f
Merge pull request #215 from launchdarkly/sunny/update-changelog-data…
lucywyman Jul 14, 2022
7b218fe
added changes
Jul 26, 2022
c1a3b89
Merge pull request #216 from launchdarkly/backmerge/release-2.7.1
Jul 26, 2022
70c9c34
upgrade go version 1.18.1 (#217)
sloloris Jul 27, 2022
8bee33e
Backmerge public/release v2.7.1 3 (#219)
ldhenry Jul 27, 2022
402b508
Remove invalid integration configurations (#221)
ldhenry Jul 28, 2022
db398b8
Add blacklist to manifest codegen and remove Zapier. (#222)
ldhenry Jul 28, 2022
b9e966d
Backmerge release 2.7.2 (#223)
ldhenry Jul 28, 2022
e7d7f77
Update Go api client to 10.0.1
Jun 28, 2022
6a6345e
Fix up v10 migration PR
Jul 28, 2022
11e3b82
Merge pull request #225 from launchdarkly/migrate-terraform-to-v10
lucywyman Jul 28, 2022
e9c8d43
[SC-160359] Create Teams resource and datasource
Jun 28, 2022
1d1e3d3
Fix up documentation
Aug 3, 2022
70e838e
Make lists unsorted to avoid unnecessary change detection
Aug 3, 2022
8fb4544
Update website/docs/d/team.html.markdown
lucywyman Aug 3, 2022
a97b4ae
Make lists unsorted to avoid unnecessary change detection
Aug 3, 2022
1cd0737
Merge pull request #224 from launchdarkly/dominickagnello/sc-160359/u…
lucywyman Aug 4, 2022
da5dacd
prepare 2.6.0 release (#91)
monsagri Apr 7, 2022
43ee03b
prepare 2.6.1 release (#94)
monsagri Apr 14, 2022
519707a
Prepare 2.7.1 release (#103)
Jul 25, 2022
1d371d9
Prepare release 2.7.1 2 (#104)
sloloris Jul 27, 2022
6276ea6
fix merge issue in Circle config (#105)
ldhenry Jul 27, 2022
76f1bcf
Release 2.7.2 (#106)
ldhenry Jul 28, 2022
416ec8b
prepare 2.8.0 release
Aug 4, 2022
8569589
Merge pull request #227 from launchdarkly/backmerge/release-2.8.0
lucywyman Aug 4, 2022
f21dd2c
[SC-163244] Add no-access role for team member resource
Aug 5, 2022
aded53f
Merge pull request #228 from launchdarkly/lucyvoigt/sc-163244/add-no-…
lucywyman Aug 5, 2022
f8caaea
Backmerge 2.9.0 release
Aug 5, 2022
72236a5
[sc-147722] add codeowners file (#230)
monsagri Aug 9, 2022
fd4a7de
Merge pull request #229 from launchdarkly/backmerge/release-2.9.0
lucywyman Aug 10, 2022
c60959a
Dominickagnello/sc 163883/open a pr against the terraform provider (#…
Blugil Aug 10, 2022
8ceb94b
add conditional so that new action only runs in private repo
Aug 10, 2022
229b5b9
Remove example.com email addresses from acceptance tests (#234)
ldhenry Aug 10, 2022
d459813
Retry failed acceptance tests once
Aug 10, 2022
e23033f
Merge pull request #235 from launchdarkly/retry-failed-tests-once
lucywyman Aug 10, 2022
124c1da
Merge pull request #233 from launchdarkly/dominickagnello/sc-163883/o…
lucywyman Aug 11, 2022
362669f
[SC-163262] Suppress diff when value_type doesn't change
Aug 5, 2022
c1ff182
Update launchdarkly/clause_helper.go
lucywyman Aug 23, 2022
a83f848
Merge pull request #236 from launchdarkly/lucyvoigt/sc-163262/don-t-s…
lucywyman Aug 24, 2022
e7affce
[bot] Regenerate integration configs (#237)
github-actions[bot] Aug 24, 2022
b8c9085
Update feature_flag_environmewnt to only create patch statements when…
ldhenry Aug 24, 2022
07e3cc0
merge public/main (#239)
ldhenry Aug 24, 2022
8311a3a
Imiller/sc 166499/defaults for boolean flags do not apply to existing…
sloloris Sep 1, 2022
9e135b6
Backmerge public (#241)
ldhenry Sep 1, 2022
c65030c
Imiller/sc 168660/terraform issue importing project with environments…
sloloris Sep 13, 2022
628672e
[SC-169876] Correctly set bucketBy to nil when empty
Sep 20, 2022
a438dfa
[SC-168865] Print error message with API errors
Sep 13, 2022
c7c9269
Merge pull request #242 from launchdarkly/lucyvoigt/sc-168865/hi-team…
lucywyman Sep 26, 2022
3dcf1bc
Merge pull request #244 from launchdarkly/lucyvoigt/sc-169876/launchd…
lucywyman Sep 26, 2022
3a6f10e
[SC-170290] Add ignore_changes guide to Terraform docs
Sep 28, 2022
8134e76
Merge pull request #245 from launchdarkly/lucyvoigt/sc-170290/update-…
lucywyman Sep 30, 2022
5f2984c
Backmerge 2.9.3 release
Oct 3, 2022
384cfb9
Merge pull request #246 from launchdarkly/backmerge/release-2.9.3
lucywyman Oct 3, 2022
259ab96
[SC-174121] Docs bug fixes
Oct 26, 2022
f8d6a58
Merge pull request #247 from launchdarkly/lucyvoigt/sc-174121/fix-gui…
lucywyman Oct 26, 2022
fae2eba
Imiller/sc 162868/update documentation on using feature flag env sett…
sloloris Oct 31, 2022
94298b1
update links to docs.launchdarkly
mmrj Jan 9, 2023
0940048
Apply some additional copy suggestions from code review
mmrj Jan 9, 2023
b88eb72
add changelog entry
mmrj Jan 10, 2023
5eb15a1
Update CHANGELOG.md
sloloris Jan 10, 2023
7342d64
Merge pull request #251 from launchdarkly/mollyjones2723/sc-182866/in…
mmrj Jan 10, 2023
dfafc3b
should not be able to set targets with empty values (#252)
sloloris Jan 10, 2023
15ee255
fix test (#255)
sloloris Jan 10, 2023
33de477
fix retry command (#254)
sloloris Jan 10, 2023
3d214ef
Update generated audit log config (#267)
sloloris Jan 27, 2023
76a985f
merge main from public?
sloloris Jan 27, 2023
f792697
backmerge (#268)
sloloris Jan 30, 2023
a2b4c4a
[bot] Regenerate integration configs (#269)
github-actions[bot] Feb 1, 2023
2289644
Add optional targeting rule descriptions (#270)
ldhenry Feb 1, 2023
f240372
[bot] Regenerate integration configs
Blugil Feb 8, 2023
143d6d0
Merge pull request #272 from launchdarkly/regenerate-integration-conf…
lucywyman Feb 9, 2023
0d4a2e5
[bot] Regenerate integration configs
Blugil Feb 9, 2023
f6b2ccd
Merge pull request #273 from launchdarkly/regenerate-integration-conf…
lucywyman Feb 9, 2023
8d57914
add ldrelease metadata (#275)
monsagri Feb 16, 2023
4fd103c
[sc 189042] update project releaser config (#276)
monsagri Feb 21, 2023
30edd7c
Releasing version 2.9.6
Feb 21, 2023
98b5c1a
[sc 189042] update project releaser config permissions (#277)
monsagri Feb 21, 2023
a9cee2a
Releasing version 2.9.6
Feb 21, 2023
562f945
[sc 189042] update project releaser artifacts (#278)
monsagri Feb 21, 2023
81b0692
Releasing version 2.9.6
Feb 21, 2023
8233722
add update-version back in (#279)
monsagri Feb 21, 2023
7f383af
Releasing version 2.9.7
Feb 21, 2023
db1bbff
fix changelog (#280)
monsagri Feb 21, 2023
e3061c6
Releasing version 2.9.7
Feb 21, 2023
66c0c5b
(maint) Document 'archived' attribute of feature_flag
Feb 21, 2023
a834b44
[sc 189042] automate terraform provider releases 2 (#282)
monsagri Feb 22, 2023
23dcf51
Merge pull request #281 from launchdarkly/add-archive-docs
lucywyman Feb 22, 2023
0d0a853
Imiller/sc 189789/investigate workarounds for default CSA issue (#283)
sloloris Feb 27, 2023
f567041
Remove tests (#284)
sloloris Feb 27, 2023
8203c0a
Maint/fix backlog conflict (#285)
monsagri Feb 27, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:
command: TESTARGS="-run TestAccEnvironment" make testacc-with-retry
- run:
name: Test Feature Flag Resource
command: TESTARGS="-run TestAccFeatureFlag" make testacc-with-retry
command: TESTARGS="-run TestAccFeatureFlag_" make testacc-with-retry
- run:
name: Test Feature Flag Environment Resource
command: TESTARGS="-run TestAccFeatureFlagEnvironment" make testacc-with-retry
Expand Down
64 changes: 0 additions & 64 deletions .github/workflows/release.yml

This file was deleted.

9 changes: 7 additions & 2 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Visit https://goreleaser.com for documentation on how to customize this
# behavior.
# TODO: Figure out why this won't grab the correct dir off env
# dist: {{ .Env.LD_RELEASE_ARTIFACTS_DIR }} // fails with unmarshal errors: cannot unmarshal !!map into string
# dist: "{{ .Env.LD_RELEASE_ARTIFACTS_DIR }}" // Doesn't replace the variable with actual value
# Below is the default that project-releaser sets - we can probably leave this hardcoded for now as it won't change
dist: /tmp/project-releaser/artifacts
before:
hooks:
# this is just an example and not a requirement for provider building/publishing
Expand Down Expand Up @@ -48,7 +53,7 @@ signs:
- "--detach-sign"
- "${artifact}"
release:
# Visit your project's GitHub Releases page to publish this release.
draft: true
# Actually creating the release is handled by project-releaser
disable: true
changelog:
skip: true
5 changes: 5 additions & 0 deletions .ldrelease/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/bash

set -ue

echo "Skipping build step as we want to build artifacts after tagging in the publish step"
18 changes: 18 additions & 0 deletions .ldrelease/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: 2

repo:
public: terraform-provider-launchdarkly
private: terraform-provider-launchdarkly-private

jobs:
- docker:
image: golang:1.18-buster
copyGitHistory: true
template:
name: go
# We run the tests as part of every merge
skip:
- test

branches:
- name: main
19 changes: 19 additions & 0 deletions .ldrelease/prepare.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/bin/bash

set -ue
# Prep for getting goreleaser
echo 'deb [trusted=yes] https://repo.goreleaser.com/apt/ /' | tee /etc/apt/sources.list.d/goreleaser.list
apt-get update
# Get goreleaser and gnupg
apt-get install -y --no-install-recommends \
goreleaser \
gnupg \
; \

# Get GPG Key
echo -e "$(cat "${LD_RELEASE_SECRETS_DIR}/gpg_private_key")" | gpg --import --batch --no-tty
echo "hello world" > temp.txt
gpg --detach-sig --yes -v --output=/dev/null --pinentry-mode loopback --passphrase "$(cat "${LD_RELEASE_SECRETS_DIR}/gpg_passphrase")" temp.txt
rm temp.txt
# Set it to env
export GPG_FINGERPRINT=$(gpg --with-colons --list-keys | awk -F: '/^pub/ { print $5 }')
15 changes: 15 additions & 0 deletions .ldrelease/publish-dry-run.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash

set -ue

# Run goreleaser
# We can't run in the build step, as project-releaser only tags the commit after the build step finishes and goreleaser pulls the tag off the most recent commit
GPG_FINGERPRINT=$(gpg --with-colons --list-keys | awk -F: '/^pub/ { print $5 }') GITHUB_TOKEN="$(cat "${LD_RELEASE_SECRETS_DIR}/github_token")" LD_RELEASE_ARTIFACTS_DIR="${LD_RELEASE_ARTIFACTS_DIR}" goreleaser release --clean --snapshot

# Remove extra files that we don't want in our release
rm /tmp/project-releaser/artifacts/artifacts.json
rm /tmp/project-releaser/artifacts/metadata.json
rm /tmp/project-releaser/artifacts/config.yaml
# Remove the binaries themselves as goreleaser puts them in subfolders
# We only want to keep the .zip files to release
rm -rf /tmp/project-releaser/artifacts/*/
15 changes: 15 additions & 0 deletions .ldrelease/publish.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash

set -ue

# Run goreleaser
# We can't run in the build step, as project-releaser only tags the commit after the build step finishes and goreleaser pulls the tag off the most recent commit
GPG_FINGERPRINT=$(gpg --with-colons --list-keys | awk -F: '/^pub/ { print $5 }') GITHUB_TOKEN="$(cat "${LD_RELEASE_SECRETS_DIR}/github_token")" goreleaser release --clean --release-notes ../entry.tmp

# Remove extra files that we don't want in our release
rm /tmp/project-releaser/artifacts/artifacts.json
rm /tmp/project-releaser/artifacts/metadata.json
rm /tmp/project-releaser/artifacts/config.yaml
# Remove the binaries themselves as goreleaser puts them in subfolders
# We only want to keep the .zip files to release
rm -rf /tmp/project-releaser/artifacts/*/
4 changes: 4 additions & 0 deletions .ldrelease/secrets.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
gpg_private_key=blob:/terraform-provider/private.pgp
gpg_passphrase=param:/production/common/releasing/terraform-provider/gpg-passphrase
# This token is the default config token for the releaser, set in it's releaser.conf
github_token=param:/staging/common/services/github/releaser_access_token
21 changes: 20 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
## [2.10.0] - 2023-02-27
FEATURES:
- Adds the optional `description` argument to the nested `rules` blocks on the `launchdarkly_feature_flag_environment` resource and data source.

BUG FIXES:

- Fixes an issue on the `launchdarkly_feature_flag` resource affecting some customers where the `client_side_availability` property would sometimes unexpectedly update. Also updates the behavior of that field to not default back to project defaults even if removed, in keeping with [the behavior of the LaunchDarkly API](https://docs.launchdarkly.com/home/organize/projects/?q=project#project-flag-defaults). If a feature flag resource is created for the first time without `client_side_availability` set, it will be set to the project defaults.

## [2.9.5] - 2023-01-30

BUG FIXES:

- Fixes a bug that allowed target blocks to be defined with no values in Terraform, resulting in a plan differential post-apply. A minimum of 1 item has been applied to the `values` field of `launchdarkly_feature_flag_environment` resource blocks.

NOTES:

- Adds a note to the `launchdarkly_feature_flag_environment` documentation to recommend against usage with experimentation.
- Updates links to LaunchDarkly product and REST API documentation.

## [2.9.4] (October 26, 2022)

BUG FIXES:
Expand All @@ -10,7 +29,7 @@ BUG FIXES:
BUG FIXES:

- Correctly set bucketBy to nil when explicitly set to an empty string to avoid API errors [#120](https://github.com/launchdarkly/terraform-provider-launchdarkly/issues/120)
- Print error message from API response for Teams resource
- Print error message from API response for `launchdarkly_team` resource

NOTES:

Expand Down
5 changes: 1 addition & 4 deletions GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,7 @@ testacc: fmtcheck
TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m

testacc-with-retry: fmtcheck
make testacc; if [ $$? -eq 1 ]; then \
printf "\n\nRetrying failed test\n\n"; \
make testacc; \
fi
make testacc || make testacc

vet:
@echo "go vet ."
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ require (
golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e // indirect
golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4 // indirect
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5 // indirect
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6 // indirect
golang.org/x/text v0.3.7 // indirect
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f // indirect
golang.org/x/text v0.3.8 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20220505152158-f39f71e6c8f3 // indirect
google.golang.org/grpc v1.46.0 // indirect
Expand Down
7 changes: 4 additions & 3 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -440,8 +440,8 @@ golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6 h1:nonptSpoQ4vQjyraW20DXPAglgQfVnM9ZC6MmNLMR60=
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
Expand All @@ -451,8 +451,9 @@ golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
golang.org/x/text v0.3.8 h1:nAL+RVCQ9uMn3vJZbV+MRnydTJFPf8qqY42YiA6MrqY=
golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ=
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
Expand Down
26 changes: 26 additions & 0 deletions launchdarkly/audit_log_subscription_configs_generated.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,32 @@
package launchdarkly

var SUBSCRIPTION_CONFIGURATION_FIELDS = map[string]IntegrationConfig{
"cloudtrail": {
"accountId": {
AllowedValues: []string{},
DefaultValue: "",
Description: "Enter your [AWS account ID](https://docs.aws.amazon.com/IAM/latest/UserGuide/console_account-alias.html#FindingYourAWSId). The associated account must be configured to use CloudTrail Lake.",
IsOptional: true,
IsSecret: false,
Type: "string",
},
"externalId": {
AllowedValues: []string{},
DefaultValue: nil,
Description: "Use this [external id](https://docs.launchdarkly.com/integrations/cloudtrail) for your resource policy when setting up the integration in the AWS Console.",
IsOptional: false,
IsSecret: false,
Type: "generated",
},
"ingestionChannelArn": {
AllowedValues: []string{},
DefaultValue: nil,
Description: "Enter the Channel ARN for LaunchDarkly to use.",
IsOptional: false,
IsSecret: false,
Type: "string",
},
},
"datadog": {
"apiKey": {
AllowedValues: []string{},
Expand Down
2 changes: 1 addition & 1 deletion launchdarkly/custom_properties_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
ldapi "github.com/launchdarkly/api-client-go/v10"
)

// https://docs.launchdarkly.com/docs/custom-properties
// https://docs.launchdarkly.com/home/connecting/custom-properties
const CUSTOM_PROPERTY_CHAR_LIMIT = 64
const CUSTOM_PROPERTY_ITEM_LIMIT = 64

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,8 @@ func TestAccDataSourceFeatureFlagEnvironment_exists(t *testing.T) {

rules := []rule{
{
Variation: intPtr(1),
Description: strPtr("test rule"),
Variation: intPtr(1),
Clauses: []ldapi.Clause{
{
Attribute: "thing",
Expand Down Expand Up @@ -155,6 +156,7 @@ func TestAccDataSourceFeatureFlagEnvironment_exists(t *testing.T) {
resource.TestCheckResourceAttr(resourceName, ENV_KEY, envKey),
resource.TestCheckResourceAttr(resourceName, ON, fmt.Sprint(thisConfig.On)),
resource.TestCheckResourceAttr(resourceName, TRACK_EVENTS, fmt.Sprint(thisConfig.TrackEvents)),
resource.TestCheckResourceAttr(resourceName, "rules.0.description", *thisConfig.Rules[0].Description),
resource.TestCheckResourceAttr(resourceName, "rules.0.variation", fmt.Sprint(*thisConfig.Rules[0].Variation)),
resource.TestCheckResourceAttr(resourceName, "rules.0.clauses.0.attribute", thisConfig.Rules[0].Clauses[0].Attribute),
resource.TestCheckResourceAttr(resourceName, "rules.0.clauses.0.op", thisConfig.Rules[0].Clauses[0].Op),
Expand Down
7 changes: 4 additions & 3 deletions launchdarkly/data_source_launchdarkly_team_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@ import (
"regexp"
"testing"

"github.com/hashicorp/terraform-plugin-sdk/v2/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
ldapi "github.com/launchdarkly/api-client-go/v10"
"github.com/stretchr/testify/require"
)

func testAccDataSourceTeamConfig(teamKey string) string {
return fmt.Sprintf(`
data "launchdarkly_team" "chicken-nugget" {
data "launchdarkly_team" "test" {
key = "%s"
}
`, teamKey)
Expand Down Expand Up @@ -66,11 +67,11 @@ func TestAccDataSourceTeam_exists(t *testing.T) {
// Populate account with dummy team
client, err := newClient(os.Getenv(LAUNCHDARKLY_ACCESS_TOKEN), os.Getenv(LAUNCHDARKLY_API_HOST), false)
require.NoError(t, err)
teamKey := "chicken-nugget"
teamKey := acctest.RandStringFromCharSet(10, acctest.CharSetAlphaNum)
team, createErr := testAccDataSourceTeamCreate(client, teamKey)
require.NoError(t, createErr)

resourceName := fmt.Sprintf("data.launchdarkly_team.%s", teamKey)
resourceName := "data.launchdarkly_team.test"
resource.Test(t, resource.TestCase{
PreCheck: func() {
testAccPreCheck(t)
Expand Down
2 changes: 1 addition & 1 deletion launchdarkly/environments_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func baseEnvironmentSchema(forProject bool) map[string]*schema.Schema {
Type: schema.TypeInt,
Optional: true,
Default: 0,
// Default TTL should be between 0 and 60 minutes: https://docs.launchdarkly.com/docs/environments
// Default TTL should be between 0 and 60 minutes: https://docs.launchdarkly.com/home/organize/environments#ttl-settings
Description: "The TTL for the environment. This must be between 0 and 60 minutes. The TTL setting only applies to environments using the PHP SDK",
ValidateDiagFunc: validation.ToDiagFunc(validation.IntBetween(0, 60)),
},
Expand Down
Loading