# Container

## Overview

In today's world, we often come across scripts (e.g. Bash, Python scripts) and code in Containers that is being used in remediating problems in the infrastructure. With this integration we support executing these scripts in our workflows and help users connect these scripts to other services available in Fylamynt.

Note that the container images used in this action node need to be set up according to <https://aws.amazon.com/blogs/aws/new-for-aws-lambda-container-image-support/>

Additionally, the target account role needs to have its **Trust Relationships** updated to allow access to the AWS lambda service, and an updated *Condition* clause as shown.

![](https://2168485084-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MXYvxfYq9m2JdKqaCdk%2F-MadjBNlHuYvMO-UBw8U%2F-MafXLUmiweCub-uBPsK%2Fimage.png?alt=media\&token=9a7da61f-8572-48f5-a4e8-0cc426e6004f)

## Use Cases

The Container integration lets you:

* Configure a container registry.
* Pick a Docker image and version that’s available in the registry.
* Pass any input to the Docker image in a text box. The input is directly passed as input when running the container.
* Enter resource requirements for the container
  * CPU (specified in CPU units).&#x20;
  * MEM (specified in MB)

## Integration Actions

* Drag the **Container** Action node onto the workflow editor canvas

![](https://2168485084-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MXYvxfYq9m2JdKqaCdk%2F-MaatLStuCnuv97PEOtM%2F-MaauSm7tVeLQrEGo_fS%2Fimage.png?alt=media\&token=d9cdb548-4a8f-43d0-ad42-34ba97f118d8)

* **Select Alias** for the target account in the dropdown

![](https://2168485084-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MXYvxfYq9m2JdKqaCdk%2F-MaatLStuCnuv97PEOtM%2F-MaauV94pZumZdLXujDQ%2Fimage.png?alt=media\&token=2748801e-7538-42e5-93fd-005b461e8635)

* **Select Repository** from the dropdown

![](https://2168485084-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MXYvxfYq9m2JdKqaCdk%2F-MaatLStuCnuv97PEOtM%2F-MaauXRUKQm2RRHotcTB%2Fimage.png?alt=media\&token=8d5494d0-8e48-423c-b683-6e77fbaf44cd)

* **Select Image** from the dropdown

![](https://2168485084-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MXYvxfYq9m2JdKqaCdk%2F-MaatLStuCnuv97PEOtM%2F-MaauZclBoo7Xq8POqCr%2Fimage.png?alt=media\&token=334ca447-a187-4e4e-b1f0-20b360db6753)

**Input**

<table data-header-hidden><thead><tr><th>Parameter Name</th><th width="342.3333333333333">Description</th><th>Required</th></tr></thead><tbody><tr><td><strong>Parameter Name</strong></td><td><strong>Description</strong></td><td><strong>Required</strong></td></tr><tr><td>alias</td><td>Target account alias for running the container</td><td>True</td></tr><tr><td>repository</td><td>Container repository in the <strong>alias</strong> target account</td><td>True</td></tr><tr><td>image</td><td>Container image SHA256 in the selected <strong>repository</strong></td><td>True</td></tr><tr><td>bucket</td><td>S3 bucket for log output from container run</td><td>False</td></tr><tr><td>command</td><td>extra command arguments</td><td>False</td></tr><tr><td>entry_point</td><td>Image entry point</td><td>False</td></tr><tr><td>memory_size</td><td>Memory size for container run, default is 128 MBytes</td><td>False</td></tr><tr><td>timeout</td><td>Timeout in seconds for the run, default is 900 seconds</td><td>False</td></tr><tr><td>working_directory</td><td>Working directory for the run</td><td>False</td></tr></tbody></table>

**Output**

| **Parameter Name** | **Type** | **Description**                                                  |
| ------------------ | -------- | ---------------------------------------------------------------- |
| bucket             | String   | S3 bucket in which log files are stored (if specified in inputs) |
| key                | String   | S3 key of log file (if a bucket was specified)                   |
| output             | String   | output from the run                                              |
| log                | String   | Last 4 KB of the execution log of the run                        |

![](https://2168485084-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MXYvxfYq9m2JdKqaCdk%2F-MaatLStuCnuv97PEOtM%2F-MaauiSAEDoobj1hcWMs%2Fimage.png?alt=media\&token=19defcdf-c1da-4a2b-89b0-8d7296f56fe8)
