반응형
macOS에 Session Manager 플러그인 설치 및 제거
설치 환경
$ aws --version
aws-cli/2.4.18 Python/3.8.8 Darwin/21.5.0 exe/x86_64 prompt/off
$ which python3
/opt/homebrew/bin/python3
aws ssm start-session --target i-0b9c5
$ aws ssm start-session --target i-0b9c5
SessionManagerPlugin is not found. Please refer to SessionManager Documentation here: http://docs.aws.amazon.com/console/systems-manager/session-manager-plugin-not-found
Session Manager 플러그인 설치
curl -s "https://s3.amazonaws.com/session-manager-downloads/plugin/latest/mac/sessionmanager-bundle.zip" -o "sessionmanager-bundle.zip"
$ curl "https://s3.amazonaws.com/session-manager-downloads/plugin/latest/mac/sessionmanager-bundle.zip" -o "sessionmanager-bundle.zip"
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 3499k 100 3499k 0 0 1400k 0 0:00:02 0:00:02 --:--:-- 1403k
unzip sessionmanager-bundle.zip
$ unzip sessionmanager-bundle.zip
Archive: sessionmanager-bundle.zip
creating: sessionmanager-bundle/
inflating: sessionmanager-bundle/LICENSE
inflating: sessionmanager-bundle/NOTICE
extracting: sessionmanager-bundle/VERSION
creating: sessionmanager-bundle/bin/
inflating: sessionmanager-bundle/bin/session-manager-plugin
inflating: sessionmanager-bundle/THIRD-PARTY
inflating: sessionmanager-bundle/install
inflating: sessionmanager-bundle/README.md
inflating: sessionmanager-bundle/RELEASENOTES.md
inflating: sessionmanager-bundle/seelog.xml.template
$ which python3
/opt/homebrew/bin/python3
/opt/homebrew/bin/python3 sessionmanager-bundle/install -h
$ /opt/homebrew/bin/python3 sessionmanager-bundle/install -h
Usage: install [options]
Options:
-h, --help show this help message and exit
-i INSTALL_DIR, --install-dir=INSTALL_DIR
The location to install the Session Manager Plugin.
The default value is /usr/local/sessionmanagerplugin
-b BIN_LOCATION, --bin-location=BIN_LOCATION
If this argument is provided, then a symlink will be
created at this location that points to the session-
manager-plugin executable. The default symlink
location is /usr/local/bin/session-manager-plugin
Note: The session-manager-plugin executable must be in
your $PATH to use Session Manager Plugin with AWS CLI.
ln -s /usr/local/sessionmanagerplugin/bin/session-manager-plugin /usr/local/bin/session-manager-plugin
ssm start-session
aws ssm start-session --target i-0b9c5
$ aws ssm start-session --target i-0b9c5
Starting session with SessionId: scbyun1-02dbe
sh-4.2$
sh-4.2$ sudo su -
Last login: Sun Jul 17 19:02:53 KST 2022 on pts/0
root@ec2:~$
참고
728x90
반응형
'퍼블릭 클라우드' 카테고리의 다른 글
AWS Command Line Interface (AWS CLI)를 최신 버전으로 설치하는 방법 (0) | 2022.07.22 |
---|---|
CNCF Cloud Native Interactive Landscape (0) | 2022.07.19 |
IAM 사용자를 위해 MFA를 강제 적용하는 정책 (0) | 2022.07.17 |
[aws] IAM 사용자가 MFA 디바이스를 스스로 관리하도록 허용 (0) | 2022.07.17 |
Amazon Linux 2에 PHP 8을 설치하는 방법 (0) | 2022.05.18 |