hashicorp / terraform-provider-bitbucket

This Terraform provider is archived per our provider archiving process: https://terraform.io/docs/internals/archiving.html
https://registry.terraform.io
Mozilla Public License 2.0
32 stars 105 forks source link

[WIP] added deploy key resource #9

Closed sjauld closed 6 years ago

sjauld commented 6 years ago

My first crack at adding a new resource - please let me know if anything else is needed.

make testacc
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test $(go list ./... |grep -v 'vendor') -v  -timeout 120m
?       github.com/terraform-providers/terraform-provider-bitbucket [no test files]
=== RUN   TestProvider
--- PASS: TestProvider (0.00s)
=== RUN   TestProvider_impl
--- PASS: TestProvider_impl (0.00s)
=== RUN   TestAccBitbucketDefaultReviewers_basic
--- PASS: TestAccBitbucketDefaultReviewers_basic (19.40s)
=== RUN   TestAccBitbucketDeployKey_basic
--- PASS: TestAccBitbucketDeployKey_basic (20.88s)
=== RUN   TestAccBitbucketHook_basic
--- PASS: TestAccBitbucketHook_basic (22.34s)
=== RUN   TestAccBitbucketRepository_basic
--- PASS: TestAccBitbucketRepository_basic (10.86s)
=== RUN   TestAccBitbucketRepository_camelcase
--- PASS: TestAccBitbucketRepository_camelcase (11.90s)
PASS
ok      github.com/terraform-providers/terraform-provider-bitbucket/bitbucket   85.394s
sjauld commented 6 years ago

cwood commented 6 years ago

My only real concern is that the validation string wont really work since we support more than just RSA.

cwood commented 6 years ago

Sorry to have negative information. But essentially we are gonna be removing all of the 1.0 API's soon(can't give specifics - watch for a blog post). Iv talked to the devs who maintain and work on the apis for us and they havnt come up with any specifics. But it is similar to users/groups.

sjauld commented 6 years ago

Sorry, are you saying that Atlassian is removing support for adding deploy keys via the API? I'm a little confused...

pdecat commented 6 years ago

On the same stance here, confused, as the same arguments were invoked to decline #6.

cwood commented 6 years ago

Essentially bitbucket will not be implementing either of these apis for the 2.0 version. And I talked to our team who maintains these apis. And they are going to deprecate these apis. So I don’t want to add these features then have to remove them later with no real plan to migrate. On Thu, Nov 9, 2017 at 10:53 PM Patrick Decat notifications@github.com wrote:

On the same stance here, confused, as the same arguments were invoked to decline #6 https://github.com/terraform-providers/terraform-provider-bitbucket/pull/6 .

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/terraform-providers/terraform-provider-bitbucket/pull/9#issuecomment-343389674, or mute the thread https://github.com/notifications/unsubscribe-auth/AAO6NcWUJwMQ6z93h1s8IEt5eGgzD7YCks5s0_LMgaJpZM4PtlC8 .

sjauld commented 6 years ago

So to confirm, Atlassian will remove the existing feature enabling the programmatic management of deploy keys?

On Fri, 10 Nov 2017 at 6:12 pm, Colin Wood notifications@github.com wrote:

Essentially bitbucket will not be implementing either of these apis for the 2.0 version. And I talked to our team who maintains these apis. And they are going to deprecate these apis. So I don’t want to add these features then have to remove them later with no real plan to migrate. On Thu, Nov 9, 2017 at 10:53 PM Patrick Decat notifications@github.com wrote:

On the same stance here, confused, as the same arguments were invoked to decline #6 < https://github.com/terraform-providers/terraform-provider-bitbucket/pull/6

.

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub < https://github.com/terraform-providers/terraform-provider-bitbucket/pull/9#issuecomment-343389674 , or mute the thread < https://github.com/notifications/unsubscribe-auth/AAO6NcWUJwMQ6z93h1s8IEt5eGgzD7YCks5s0_LMgaJpZM4PtlC8

.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/terraform-providers/terraform-provider-bitbucket/pull/9#issuecomment-343392629, or mute the thread https://github.com/notifications/unsubscribe-auth/AH2eNwUbOIMq09vBMcdwoOhh-6a6aFjqks5s0_dOgaJpZM4PtlC8 .

cwood commented 6 years ago

Yea unfortunately. I am not happy about this either. Your best bet would to make a site/master issue and ask for a 2.0 version of the deployment keys. I asked our API team again and they confirmed it.

erikvanzijst commented 6 years ago

So to confirm, Atlassian will remove the existing feature enabling the programmatic management of deploy keys?

This is correct.

We don't yet have a date for when we turn off these APIs, but we will not be creating copies of these in 2.0. I've left a more complete motivation on the site/master ticket.

cwood commented 6 years ago

Thanks for clarifying Erik On Wed, Nov 15, 2017 at 6:07 PM Erik van Zijst notifications@github.com wrote:

So to confirm, Atlassian will remove the existing feature enabling the programmatic management of deploy keys?

This is correct.

We don't yet have a date for when we turn off these APIs, but we will not be creating copies of these in 2.0. I've left a more complete motivation on the site/master ticket https://bitbucket.org/site/master/issues/15196/removal-of-10-api#comment-41240017 .

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/terraform-providers/terraform-provider-bitbucket/pull/9#issuecomment-344792364, or mute the thread https://github.com/notifications/unsubscribe-auth/AAO6NWRSDRyYlqRyuhIen6PLiBh0fxx1ks5s25jbgaJpZM4PtlC8 .