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

Add Azure Resources Integration to CLI #300

Merged
merged 7 commits into from
Aug 8, 2024
Merged

Conversation

taimoorgit
Copy link
Contributor

Issues

https://github.com/OpsLevel/team-platform/issues/414

OpsLevel/opslevel-go#430

Changelog

  • Create function
  • Update function
  • Make a changie entry

Tophatting

YAML used:

version: 1
kind: aws
spec:
  name: "Prod"
  iamRole: "arn:aws:iam::XXXXX:role/opslevel-integration"
  externalId: "XXXXXX"
  ownershipTagOverride: true
  ownershipTagKeys: ["owner","service","app"]

version: 1
kind: aws
spec:
  name: "dev"
  ownershipTagKeys: ["owner","service","application"]

version: 1
kind: azure
spec:
  name: "Azure New"
  tenantId: "12345678-1234-1234-1234-123456789abc"
  subscriptionId: "12345678-1234-1234-1234-123456789def"
  clientId: "XXX_CLIENT_ID_XXX"
  clientSecret: "XXX_CLIENT_SECRET_XXX"

version: 1
kind: azure
spec:
  name: "Azure Updated"

CLI output:

$ go run main.go create integration -f aws_create.yaml
Created aws integration 'Prod' with id 'Z2lkOi8vb3BzbGV2ZWwvSW50ZWdyYXRpb25zOjpBd3NJbnRlZ3JhdGlvbi8zNQ'
$ go run main.go update integration Z2lkOi8vb3BzbGV2ZWwvSW50ZWdyYXRpb25zOjpBd3NJbnRlZ3JhdGlvbi8zNQ -f aws_update.yaml
Updated aws integration 'dev' with id 'Z2lkOi8vb3BzbGV2ZWwvSW50ZWdyYXRpb25zOjpBd3NJbnRlZ3JhdGlvbi8zNQ'

$ go run main.go create integration -f azure_create.yaml
Created azure integration 'Azure New' with id 'Z2lkOi8vb3BzbGV2ZWwvSW50ZWdyYXRpb25zOjpBenVyZVJlc291cmNlc0ludGVncmF0aW9uLzM2'
$ go run main.go update integration Z2lkOi8vb3BzbGV2ZWwvSW50ZWdyYXRpb25zOjpBenVyZVJlc291cmNlc0ludGVncmF0aW9uLzM2 -f azure_update.yaml
Updated azure integration 'Azure Updated' with id 'Z2lkOi8vb3BzbGV2ZWwvSW50ZWdyYXRpb25zOjpBenVyZVJlc291cmNlc0ludGVncmF0aW9uLzM2'

@taimoorgit taimoorgit self-assigned this Jul 9, 2024
Copy link
Contributor

@davidbloss davidbloss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🎉

Copy link
Contributor Author

@taimoorgit taimoorgit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important changes to example that I noticed was incorrect

src/cmd/integration.go Outdated Show resolved Hide resolved
src/cmd/integration.go Outdated Show resolved Hide resolved
@davidbloss davidbloss merged commit 585b2a9 into main Aug 8, 2024
4 checks passed
@davidbloss davidbloss deleted the ta/azure-integration branch August 8, 2024 16:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants