rds_ssm_connect 1.7.16 → 1.7.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/connect.js CHANGED
@@ -14,7 +14,7 @@ import {
14
14
  } from './configLoader.js'
15
15
 
16
16
  // Package info for version checking
17
- const packageJson = { name: 'rds_ssm_connect', version: '1.7.15' }
17
+ const packageJson = { name: 'rds_ssm_connect', version: '1.7.17' }
18
18
 
19
19
  const execAsync = promisify(exec)
20
20
 
@@ -950,10 +950,12 @@ async function main() {
950
950
  const portNumber = envPortMapping[matchedSuffix] || defaultPort
951
951
 
952
952
  // Get RDS credentials from Secrets Manager
953
+ console.log('\n⏳ Getting credentials...')
953
954
  const secretsListCommand = `aws-vault exec ${ENV} -- aws secretsmanager list-secrets --region ${region} --query "SecretList[?starts_with(Name, '${secretPrefix}')].Name | [0]" --output text`
954
955
  const SECRET_NAME = await runCommand(secretsListCommand)
955
956
 
956
957
  if (!SECRET_NAME || SECRET_NAME === 'None') {
958
+ console.error('❌ No secret found with prefix:', secretPrefix)
957
959
  return
958
960
  }
959
961
 
@@ -961,6 +963,7 @@ async function main() {
961
963
  const secretString = await runCommand(secretsGetCommand)
962
964
 
963
965
  if (!secretString) {
966
+ console.error('❌ Failed to retrieve secret value')
964
967
  return
965
968
  }
966
969
 
@@ -971,30 +974,42 @@ async function main() {
971
974
  throw new Error('Missing username or password in credentials')
972
975
  }
973
976
  } catch (_error) {
977
+ console.error('❌ Failed to parse credentials')
974
978
  return
975
979
  }
976
980
 
977
- const _USERNAME = CREDENTIALS.username
978
- const _PASSWORD = CREDENTIALS.password
979
-
980
981
  // Find bastion instance
982
+ console.log('⏳ Finding bastion instance...')
981
983
  const instanceIdCommand = `aws-vault exec ${ENV} -- aws ec2 describe-instances --region ${region} --filters "Name=tag:Name,Values='*bastion*'" "Name=instance-state-name,Values=running" --query "Reservations[].Instances[].[InstanceId] | [0][0]" --output text`
982
984
  const INSTANCE_ID = await runCommand(instanceIdCommand)
983
985
 
984
986
  if (!INSTANCE_ID || INSTANCE_ID === 'None') {
987
+ console.error('❌ No running bastion instance found')
985
988
  return
986
989
  }
987
990
 
988
991
  // Get RDS endpoint
992
+ console.log('⏳ Getting RDS endpoint...')
989
993
  const RDS_ENDPOINT = await getRdsEndpoint(ENV, projectConfig)
990
994
 
991
995
  if (!RDS_ENDPOINT || RDS_ENDPOINT === 'None') {
996
+ console.error('❌ Failed to find RDS endpoint')
992
997
  return
993
998
  }
994
999
 
995
1000
  // Get RDS port (remote port)
996
1001
  const rdsPort = await getRdsPort(ENV, projectConfig)
997
1002
 
1003
+ // Print connection details
1004
+ console.log('\n✅ Connection details:')
1005
+ console.log(` Host: localhost`)
1006
+ console.log(` Port: ${portNumber}`)
1007
+ console.log(` Username: ${CREDENTIALS.username}`)
1008
+ console.log(` Password: ${CREDENTIALS.password}`)
1009
+ console.log(` Database: ${projectConfig.database}`)
1010
+ console.log(`\n⏳ Starting port forwarding...`)
1011
+ console.log(' Press Ctrl+C to disconnect\n')
1012
+
998
1013
  await startPortForwardingWithConfig(
999
1014
  ENV,
1000
1015
  INSTANCE_ID,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rds_ssm_connect",
3
- "version": "1.7.16",
3
+ "version": "1.7.17",
4
4
  "type": "module",
5
5
  "repository": {
6
6
  "type": "git",
@@ -3057,7 +3057,7 @@ checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539"
3057
3057
 
3058
3058
  [[package]]
3059
3059
  name = "rds-ssm-connect"
3060
- version = "1.7.16"
3060
+ version = "1.7.17"
3061
3061
  dependencies = [
3062
3062
  "reqwest 0.12.28",
3063
3063
  "semver",
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "rds-ssm-connect"
3
- version = "1.7.16"
3
+ version = "1.7.17"
4
4
  description = "Secure RDS connections through AWS SSM"
5
5
  authors = ["Iaroslav Pyrogov"]
6
6
  edition = "2024"
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://schema.tauri.app/config/2",
3
3
  "productName": "RDS SSM Connect",
4
- "version": "1.7.16",
4
+ "version": "1.7.17",
5
5
  "identifier": "com.rds-ssm-connect.desktop",
6
6
  "build": {
7
7
  "beforeDevCommand": "npm run dev:vite",