Home

Awesome

ecsexec

ecsexec is a tool designed to access a shell session within a container running in an ECS task.

Prerequisites

Before using ecsexec, ensure that you have the following prerequisites installed on your local machine:

  1. AWS CLI: The AWS Command Line Interface (CLI) is required for managing AWS resources from the command line. Installation instructions for the AWS CLI can be found in the AWS documentation: Installing the AWS CLI.

  2. Session Manager Plugin (session-manager-plugin): Installation instructions for session-manager-plugin can be found in the AWS documentation: Session Manager Plugin Installation.

Installation

You can install this tool by running the following command:

Homebrew

brew install Taiki130/ecsexec/ecsexec

go

go install -a github.com/Taiki130/ecsexec/cmd/ecsexec@latest

Usage

The ecsexec command can be used with the following syntax:

ecsexec [global options]

Interactive Prompt

If any of the required information is not provided through environment variables or command-line options, ecsexec will prompt you interactively to select the necessary details.

Global Options

Examples

Simple Usage Example

ecsexec

Specifying flags Example

ecsexec --region us-east-1 --cluster my-cluster --service my-service --container my-container

Specifying a Login Shell Example

ecsexec --command /bin/bash

Configuration

You can customize the behavior of the ecsexec command using environment variables. Here are the available environment variables:

License

This project is licensed under the MIT License. See the LICENSE file for details.