Phase 2 Implementation: - HMAC authentication for engine-to-bot communication - Request signing with timestamp anti-replay - Response signing for integrity verification - HTTP bot client with timeout and crash detection - Per-turn 3s timeout, 10 consecutive failure crash threshold - Move validation (position ownership, direction validity) - Integration tests for HTTP match execution - 6 strategy bots in 6 languages: - RandomBot (Python): Random valid moves - rating floor - GathererBot (Go): Energy-focused with combat avoidance - RusherBot (Rust): Aggressive core rushing via BFS - GuardianBot (PHP): Defensive core protection - SwarmBot (TypeScript): Formation-based group combat - HunterBot (Java): Target isolation and hunting All bots include: - HMAC signature verification - Dockerfile for containerization - README documentation All engine tests passing (32+ tests) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
23 lines
429 B
Docker
23 lines
429 B
Docker
# Build stage
|
|
FROM eclipse-temurin:21-jdk-alpine AS builder
|
|
|
|
WORKDIR /app
|
|
COPY pom.xml ./
|
|
COPY src ./src
|
|
|
|
# Install Maven and build
|
|
RUN apk add --no-cache maven && \
|
|
mvn clean package -DskipTests
|
|
|
|
# Runtime stage
|
|
FROM eclipse-temurin:21-jre-alpine
|
|
|
|
WORKDIR /app
|
|
COPY --from=builder /app/target/hunter-bot-1.0.0.jar /app/hunter-bot.jar
|
|
|
|
ENV BOT_PORT=8085
|
|
ENV BOT_SECRET=""
|
|
|
|
EXPOSE 8085
|
|
|
|
CMD ["java", "-jar", "hunter-bot.jar"]
|