Skip to content

Instantly share code, notes, and snippets.

@thimslugga
Last active March 4, 2026 14:34
Show Gist options
  • Select an option

  • Save thimslugga/b715168eae3fd0074e07eb3c8b4583cd to your computer and use it in GitHub Desktop.

Select an option

Save thimslugga/b715168eae3fd0074e07eb3c8b4583cd to your computer and use it in GitHub Desktop.
Kiro CLI Container Images

Kiro CLI Container Image

Overview

#!/bin/bash
podman build -t kiro-cli -f Containerfile .
version: '3.8'
volumes:
kiro-cli-data:
driver: local
services:
kiro-cli:
container_name: kiro-cli
build:
context: ..
dockerfile: ./Containerfile
environment:
- KIRO_START_URL=${KIRO_START_URL:-https://amzn.awsapps.com/start}
- KIRO_LOGIN_REGION=${KIRO_LOGIN_REGION:-us-east-1}
- KIRO_LICENSE=${KIRO_LICENSE:-pro}
volumes:
- kiro-cli-data:/root/.local/share/kiro-cli
restart: unless-stopped
stdin_open: true
tty: true
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
FROM public.ecr.aws/amazonlinux/amazonlinux:2023 AS installer
RUN dnf install --allowerasing -y \
curl \
unzip \
&& dnf clean all \
&& rm -rf /var/cache/dnf ;
USER ec2-user
RUN curl -fsSL https://cli.kiro.dev/install | bash
FROM public.ecr.aws/amazonlinux/amazonlinux:2023-minimal
RUN dnf install --allowerasing -y \
git \
git-lfs \
iputils \
&& dnf clean all \
&& rm -rf /var/cache/dnf ;
WORKDIR /app
COPY --from=installer /home/ec2-user/.local/bin/ /home/ec2-user/.local/bin/
COPY --from=installer /home/ec2-user/.kiro/bin/ /home/ec2-user/.kiro/bin/
RUN chown -R ec2-user:ec2-user /app /home/ec2-user/.local /home/ec2-user/.kiro
USER ec2-user
ENV PATH="/home/ec2-user/.local/bin:/home/ec2-user/.kiro/bin:${PATH}"
ENTRYPOINT ["kiro-cli"]
# https://docs.aws.amazon.com/linux/al2023/ug/minimal-container.html
FROM public.ecr.aws/amazonlinux/amazonlinux:2023-minimal
RUN dnf install -y --allowerasing \
bash \
curl \
git \
gzip \
iputils \
tar \
unzip \
&& dnf clean all \
&& rm -rf /var/cache/dnf; \
useradd -m -s /bin/bash kiro
USER kiro
WORKDIR /home/kiro
# Install kiro-cli
RUN curl -sSfL https://cli.kiro.dev/install | bash -s -- --no-confirm
ENV PATH="/home/kiro/.local/bin:${PATH}"
CMD ["bash"]
FROM ubuntu:24.04
RUN \
apt-get update \
&& apt-get install -y \
git \
ripgrep \
curl \
iputils-ping \
unzip \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
RUN chown -R ubuntu:ubuntu /app
USER ubuntu
ENV PATH="/home/ubuntu/.local/bin:/home/ubuntu/.kiro/bin:${PATH}"
# Install kiro-cli
RUN curl -fsSL https://cli.kiro.dev/install | bash
ENTRYPOINT ["kiro-cli"]
#!/bin/bash
podman run -it --rm \
-v ${HOME}/.kiro:/home/kiro/.kiro:z \
-v ${PWD}:/workspace:z \
-w /workspace \
kiro-cli
# Inside the container
#kiro-cli login
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment