Skip to content

Commit

Permalink
Feat/update secrets on expected response (#79)
Browse files Browse the repository at this point in the history
* feat: update secrets on expected response

Signed-off-by: Ariel Septon <arielsepton@Ariels-MBP.lan>

* bump version to v1.0.8

Signed-off-by: Ariel Septon <arielsepton@Ariels-MBP.lan>

---------

Signed-off-by: Ariel Septon <arielsepton@Ariels-MBP.lan>
Co-authored-by: Ariel Septon <arielsepton@Ariels-MBP.lan>
  • Loading branch information
arielsepton and Ariel Septon authored Jan 3, 2025
1 parent 511cf20 commit b88c356
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/promote.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
workflow_dispatch:
inputs:
version:
description: "Release version (e.g. v1.0.7)"
description: "Release version (e.g. v1.0.8)"
required: true
channel:
description: "Release channel"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
workflow_dispatch:
inputs:
version:
description: "Release version (e.g. v1.0.7)"
description: "Release version (e.g. v1.0.8)"
required: true
message:
description: "Tag message"
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ To install `provider-http`, you have two options:
1. Using the Crossplane CLI in a Kubernetes cluster where Crossplane is installed:

```console
crossplane xpkg install provider xpkg.upbound.io/crossplane-contrib/provider-http:v1.0.7
crossplane xpkg install provider xpkg.upbound.io/crossplane-contrib/provider-http:v1.0.8
```

2. Manually creating a Provider by applying the following YAML:
Expand All @@ -20,7 +20,7 @@ To install `provider-http`, you have two options:
metadata:
name: provider-http
spec:
package: "xpkg.upbound.io/crossplane-contrib/provider-http:v1.0.7"
package: "xpkg.upbound.io/crossplane-contrib/provider-http:v1.0.8"
```
## Supported Resources
Expand Down
2 changes: 1 addition & 1 deletion deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ kind: Provider
metadata:
name: http-provider
spec:
package: xpkg.upbound.io/crossplane-contrib/provider-http:v1.0.7
package: xpkg.upbound.io/crossplane-contrib/provider-http:v1.0.8
controllerConfigRef:
name: debug-config

Expand Down
5 changes: 3 additions & 2 deletions internal/controller/disposablerequest/disposablerequest.go
Original file line number Diff line number Diff line change
Expand Up @@ -234,8 +234,9 @@ func (c *external) deployAction(ctx context.Context, cr *v1alpha2.DisposableRequ
return err
}

datapatcher.ApplyResponseDataToSecrets(ctx, c.localKube, c.logger, &resource.HttpResponse, cr.Spec.ForProvider.SecretInjectionConfigs, cr)
if !isExpectedResponse {
if isExpectedResponse {
datapatcher.ApplyResponseDataToSecrets(ctx, c.localKube, c.logger, &resource.HttpResponse, cr.Spec.ForProvider.SecretInjectionConfigs, cr)
} else {
limit := utils.GetRollbackRetriesLimit(cr.Spec.ForProvider.RollbackRetriesLimit)
return utils.SetRequestResourceStatus(*resource, resource.SetStatusCode(), resource.SetLastReconcileTime(), resource.SetHeaders(), resource.SetBody(),
resource.SetError(errors.New(errResponseFormat+fmt.Sprint(limit))), resource.SetRequestDetails())
Expand Down

0 comments on commit b88c356

Please sign in to comment.