Skip to content

Commit 18fd93b

Browse files
committed
Add GitHub Actions docker build for alf image
1 parent aeab76e commit 18fd93b

2 files changed

Lines changed: 46 additions & 0 deletions

File tree

.github/workflows/docker-build.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Build and Push Docker Image
2+
3+
on:
4+
push:
5+
branches: [alfworld-base-adapted]
6+
workflow_dispatch: # ← allows manual trigger from GitHub UI
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest # ← native linux/amd64, no emulation
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v3
14+
15+
- name: Login to GitHub Container Registry
16+
uses: docker/login-action@v2
17+
with:
18+
registry: ghcr.io
19+
username: ${{ github.actor }}
20+
password: ${{ secrets.GITHUB_TOKEN }}
21+
22+
- name: Build and Push
23+
uses: docker/build-push-action@v4
24+
with:
25+
context: .
26+
file: Dockerfile-alf
27+
push: true
28+
tags: ghcr.io/amit502/reflexion:alf

Dockerfile-alf

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
FROM python:3.9-slim
2+
3+
# Install system dependencies
4+
RUN apt-get update && apt-get install -y \
5+
git \
6+
build-essential \
7+
gcc \
8+
make \
9+
&& rm -rf /var/lib/apt/lists/*
10+
11+
# Set working directory
12+
WORKDIR /app
13+
14+
# Install alfworld text-only version
15+
RUN pip install --no-cache-dir alfworld==0.3.3
16+
17+
# Default command (overridden by the job YAML at runtime)
18+
CMD ["bash"]

0 commit comments

Comments
 (0)