-
Notifications
You must be signed in to change notification settings - Fork 154
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
Fix import resources with provider default tags #4169
Merged
Merged
Changes from 17 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
276cafb
Fix import resources with provider default tags
corymhall e573c99
skip test
corymhall 0063967
fixing test
corymhall 18cc1c4
Adding more tests
corymhall 892e985
Merge remote-tracking branch 'origin/master' into corymhall/default-t…
corymhall e24dbfa
Add a note
corymhall 7852b77
trying to fix upstream
corymhall 28ff3a5
run go mod tidy
corymhall 9095918
adding parallel to tests
corymhall 6a9f36c
Merge branch 'master' into corymhall/default-tags-import
corymhall 5f51229
Fixing tests
corymhall 54a9732
fixing spelling
corymhall 25b4b15
adding pf tests to some additional tags tests
corymhall d4c01b7
Merge remote-tracking branch 'origin/master' into corymhall/default-t…
corymhall 185f434
adding test for .get methods
corymhall e84e096
run go mod tidy
corymhall 5fe2ef0
Merge branch 'master' into corymhall/default-tags-import
corymhall 8c72e64
updating based on comments
corymhall File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -71,12 +71,40 @@ func main() { | |
return err | ||
} | ||
|
||
env, err := appconfig.NewEnvironment(ctx, "testappconfigenv"+testIdent, &appconfig.EnvironmentArgs{ | ||
ApplicationId: app.ID(), | ||
Tags: tagsMap, | ||
}, pulumi.Provider(p)) | ||
if err != nil { | ||
return err | ||
} | ||
|
||
getEnv, err := appconfig.GetEnvironment(ctx, "get-testappconfigenv"+testIdent, env.ID(), &appconfig.EnvironmentState{}, pulumi.Provider(p)) | ||
if err != nil { | ||
return err | ||
} | ||
|
||
// refresh doesn't work for `forceDelete` & `acl` uncomment when fixed | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is interesting, is this something worth linking a ticket to? Thank you. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added another comment with link to the issue. |
||
// getBucket, err := s3.GetBucketV2(ctx, "get-bucketv2"+testIdent, bucket.ID(), &s3.BucketV2State{}, pulumi.Provider(p), pulumi.IgnoreChanges([]string{"forceDestroy", "acl"})) | ||
// if err != nil { | ||
// return err | ||
// } | ||
// getLegacyBucket, err := s3.GetBucket(ctx, "get-legacybucket"+testIdent, legacyBucket.ID(), &s3.BucketState{}, pulumi.Provider(p), pulumi.IgnoreChanges([]string{"forceDestroy", "acl"})) | ||
// if err != nil { | ||
// return err | ||
// } | ||
|
||
ctx.Export("bucket", exportTags(bucket.Tags)) | ||
// ctx.Export("get-bucket", exportTags(getBucket.Tags)) | ||
ctx.Export("legacy-bucket", exportTags(legacyBucket.Tags)) | ||
// ctx.Export("get-legacy-bucket", exportTags(getLegacyBucket.Tags)) | ||
ctx.Export("bucket-name", bucket.Bucket) | ||
ctx.Export("legacy-bucket-name", legacyBucket.Bucket) | ||
ctx.Export("appconfig-app", exportTags(app.Tags)) | ||
ctx.Export("appconfig-app-arn", app.Arn) | ||
ctx.Export("appconfig-env", exportTags(env.Tags)) | ||
ctx.Export("get-appconfig-env", exportTags(getEnv.Tags)) | ||
ctx.Export("appconfig-env-arn", env.Arn) | ||
|
||
return nil | ||
}) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these comments still useful?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added another comment with link to the issue. When the issue is fixed the code can be uncommented.