Skip to content

Commit

Permalink
Getting svid-2
Browse files Browse the repository at this point in the history
Signed-off-by: PrimalPimmy <Prashant20.pm@gmail.com>
  • Loading branch information
PrimalPimmy committed Jul 18, 2024
1 parent 3a2ce0a commit bde4674
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions controllers/pkg/reconcilers/spire-bootstrap/reconciler.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,13 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu

vaultAddr := "http://10.146.0.21:8200"

jwtSVID, err := resource.GetJWT(ctx)
if err != nil {
log.Error(err, "Unable to get jwtSVID")
}

fmt.Println("TESTTT 4444444")

workloadAPIAddr := flag.String("workload-api-addr", "", "Workload API Address")
flag.Parse()

Expand All @@ -142,13 +149,6 @@ func (r *reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Resu
err = workloadapi.WatchX509Context(context.Background(), resource.Watcher{}, opts...)
log.Error(err, "Error: ")

jwtSVID, err := resource.GetJWT(ctx)
if err != nil {
log.Error(err, "Unable to get jwtSVID")
}

fmt.Println("TESTTT 4444444")

clientToken, err := vaultClient.AuthenticateToVault(vaultAddr, jwtSVID.Marshal(), "dev")
if err != nil {
log.Error(err, "Error authenticating to Vault:")
Expand Down

0 comments on commit bde4674

Please sign in to comment.