You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A cross-platform SSH proxy command for connecting VSCode to CloudX/Cloud9 EC2 instances using AWS Systems Manager Session Manager.
13
13
14
14
## Overview
15
15
16
-
cloudX-proxy enables seamless SSH connections from VSCode to EC2 instances using AWS Systems Manager Session Manager, eliminating the need for direct SSH access or public IP addresses. It handles:
16
+
cloudx-proxy enables seamless SSH connections from VSCode to EC2 instances using AWS Systems Manager Session Manager, eliminating the need for direct SSH access or public IP addresses. It handles:
17
17
18
18
- Automatic instance startup if stopped
19
19
- SSH key distribution via EC2 Instance Connect
@@ -54,7 +54,7 @@ cloudX-proxy enables seamless SSH connections from VSCode to EC2 instances using
54
54
55
55
## Prerequisites
56
56
57
-
1.**Python 3.9+** - Required for cloudX-proxy and uv package manager
57
+
1.**Python 3.9+** - Required for cloudx-proxy and uv package manager
- Check your version: `python --version` or `python3 --version`
60
60
- Supports Python 3.9, 3.10, 3.11, 3.12, 3.13
@@ -84,7 +84,7 @@ cloudX-proxy enables seamless SSH connections from VSCode to EC2 instances using
84
84
- Downloads and installs the package and its dependencies
85
85
- Runs the package without explicit environment activation
86
86
87
-
This means you can run cloudX-proxy directly with `uvx cloudx-proxy` without manually managing virtual environments or dependencies.
87
+
This means you can run cloudx-proxy directly with `uvx cloudx-proxy` without manually managing virtual environments or dependencies.
88
88
89
89
6.**VSCode with Remote SSH Extension** - Your development environment
90
90
- Provides the integrated development environment
@@ -93,11 +93,11 @@ cloudX-proxy enables seamless SSH connections from VSCode to EC2 instances using
93
93
94
94
## Installation
95
95
96
-
The cloudX-proxy package is available on PyPI and can run using uvx without explicit installation.
96
+
The cloudx-proxy package is available on PyPI and can run using uvx without explicit installation.
97
97
98
98
## Setup
99
99
100
-
cloudX-proxy includes a setup command that automates the entire configuration process:
100
+
cloudx-proxy includes a setup command that automates the entire configuration process:
101
101
102
102
```bash
103
103
# Basic setup with defaults (vscode profile and key)
@@ -131,6 +131,8 @@ The setup command will:
131
131
132
132
2. Manage SSH Keys:
133
133
- Creates new SSH key pair if needed
134
+
* Defaults to key name "vscode" in ~/.ssh/vscode/
135
+
* Custom key name/location via --ssh-key and --ssh-config
134
136
- Fully supports 1Password integration:
135
137
* Using 1Password SSH agent via `--1password` flag
136
138
* Creates keys directly in 1Password's secure vault
@@ -151,7 +153,7 @@ The setup command will:
151
153
152
154
### SSH Configuration
153
155
154
-
The setup command configures SSH to use cloudX-proxy as a ProxyCommand, enabling seamless connections through AWS Systems Manager. For example, running:
156
+
The setup command configures SSH to use cloudx-proxy as a ProxyCommand, enabling seamless connections through AWS Systems Manager. For example, running:
-`--profile` (default: vscode): AWS profile to use. The profile's IAM user should follow the format cloudX-{env}-{user}. The environment part will be used as the default environment during setup.
350
+
-`--profile` (default: vscode): AWS profile to use. The profile's IAM user should follow the format cloudX-{env}-{user}. The environment part will be used as the default environment during setup. When the profile is an SSO profile (role), ensure you have logged in using `aws sso login --profile {profile}` before running the setup and when connecting.
349
351
-`--ssh-key` (default: vscode): Name of the SSH key to create/use. The key will be stored in the SSH config directory. This same name can be used in the connect command.
350
352
-`--ssh-config` (optional): Path to the SSH config file to use. If specified, configuration and keys will be stored in this location. Default is ~/.ssh/vscode/config.
351
-
-`--1password` (optional): Enable 1Password SSH agent integration. Can be used as a flag or with a vault name (e.g., `--1password Private`). First searches all vaults for existing keys with name "cloudX SSH Key - {keyname}". If no existing key found, creates new keys directly in the specified (or selected) 1Password vault and configures SSH to use the 1Password SSH agent. If a vault name is specified, that vault will be used for key storage; otherwise, prompts user to select from available vaults. By default, the "Private" vault is used when no vault specified. Note that only the "Private" vault is enabled for SSH by default in 1Password settings - other vaults must be manually enabled in 1Password SSH agent settings.
353
+
-`--1password` (optional): Enable 1Password SSH agent integration. Can be used as a flag or with a vault name (e.g., `--1password Private`). First searches all vaults for existing keys with name "cloudX SSH Key - {keyname}". If no existing key found, creates new keys directly in the specified (or selected) 1Password vault and configures SSH to use the 1Password SSH agent. If a vault name is specified, that vault will be used for key storage. By default, the "Private" vault is used when no vault specified. Note that only the "Private" vault is enabled for SSH by default in 1Password settings - other vaults must be manually enabled in 1Password SSH agent settings.
352
354
-`--aws-env` (optional): AWS environment directory to use. If specified, AWS configuration and credentials will be read from ~/.aws/aws-envs/{env}/.
353
355
-`--instance` (optional): EC2 instance ID to set up connection for. If provided, skips the instance ID prompt.
354
356
-`--hostname` (optional): Hostname to use for SSH configuration. If not provided, a hostname will be generated from the instance ID in non-interactive mode or prompted for in interactive mode.
@@ -441,7 +443,7 @@ The list command displays all configured cloudx-proxy hosts, grouped by environm
441
443
2. Select "SSH Targets" from the dropdown
442
444
3. Your configured hosts will appear (e.g., cloudx-dev)
443
445
4. Click the "+" icon next to a host to connect
444
-
5. VSCode will handle the rest, using cloudX-proxy to establish the connection
446
+
5. VSCode will handle the rest, using cloudx-proxy to establish the connection
445
447
446
448
## AWS Permissions
447
449
### IAM User Permissions
@@ -457,6 +459,44 @@ Note: This user should be created using the cloudX-user product from Service Cat
457
459
458
460
The EC2 instance should have the tag `cloudxuser` with the value of the username of the user that is connecting to the instance. This is automatically set when the instance is created using the cloudX-instance product from Service Catalog in the AWS Console.
459
461
462
+
463
+
### IAM Role Permissions
464
+
465
+
In organizations with AWS IAM Identity Center (formerly AWS SSO), the IAM entity is often a role that is assumed by the user. The role must have the same permissions as described for the IAM user above, typically in the form of a permission set. ABAC aside, the following permissions are required for the role:
0 commit comments