Skip to content
This repository has been archived by the owner on Sep 16, 2024. It is now read-only.

Commit

Permalink
fix: deployment with exipred token
Browse files Browse the repository at this point in the history
Signed-off-by: thxCode <[email protected]>
  • Loading branch information
thxCode authored and alexcodelf committed Aug 15, 2023
1 parent d53a6ef commit 881b7a1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/deployer/terraform/deployer.go
Original file line number Diff line number Diff line change
Expand Up @@ -539,10 +539,10 @@ func (d Deployer) LoadConfigsBytes(ctx context.Context, opts CreateSecretsOption
opts.ServiceRevision.ID))

// Prepare API token for terraform backend.
const _30Min = 1800
const _1Day = 60 * 60 * 24

at, err := auths.CreateAccessToken(ctx,
d.modelClient, opts.SubjectID, types.TokenKindDeployment, string(opts.ServiceRevision.ID), pointer.Int(_30Min))
d.modelClient, opts.SubjectID, types.TokenKindDeployment, string(opts.ServiceRevision.ID), pointer.Int(_1Day))
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 881b7a1

Please sign in to comment.