Skip to content

Commit

Permalink
tsh --cluster saves oracle wallet to leaf dir
Browse files Browse the repository at this point in the history
  • Loading branch information
GavinFrazar authored and github-actions committed Nov 7, 2024
1 parent 54a7530 commit ed88eac
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/client/db/oracle/oracle.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ import (
// wallet.jks - Java Wallet format used by JDBC Drivers.
// sqlnet.ora - Generic Oracle Client Configuration File allowing to specify Wallet Location.
// tnsnames.ora - Oracle Net Service mapped to connections descriptors.
func GenerateClientConfiguration(signer crypto.Signer, db tlsca.RouteToDatabase, profile *client.ProfileStatus) error {
walletPath := profile.OracleWalletDir(profile.Cluster, db.ServiceName)
func GenerateClientConfiguration(signer crypto.Signer, db tlsca.RouteToDatabase, profile *client.ProfileStatus, siteName string) error {
walletPath := profile.OracleWalletDir(siteName, db.ServiceName)
if err := os.MkdirAll(walletPath, teleport.PrivateDirMode); err != nil {
return trace.Wrap(err)
}
Expand Down
2 changes: 1 addition & 1 deletion tool/tsh/common/db.go
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ func databaseLogin(cf *CLIConf, tc *client.TeleportClient, dbInfo *databaseInfo)
if err := generateDBLocalProxyCert(keyRing.TLSPrivateKey, profile); err != nil {
return trace.Wrap(err)
}
err = oracle.GenerateClientConfiguration(keyRing.TLSPrivateKey, dbInfo.RouteToDatabase, profile)
err = oracle.GenerateClientConfiguration(keyRing.TLSPrivateKey, dbInfo.RouteToDatabase, profile, tc.SiteName)
if err != nil {
return trace.Wrap(err)
}
Expand Down

0 comments on commit ed88eac

Please # to comment.