diff --git a/.env.example b/.env.example index bddc1d6..c60e9da 100644 --- a/.env.example +++ b/.env.example @@ -2,6 +2,7 @@ DISCORD_TOKEN="" # Container configuration +IMAGE="" ROOT_DIR="" # Himbucks System Configuration diff --git a/Dockerfile b/Dockerfile index 90a55d1..9d8a960 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,7 +19,14 @@ RUN apt-get update && apt-get install -y \ ca-certificates \ && rm -rf /var/lib/apt/lists/* -COPY --from=build /go/bin/app /app +# Create app directory +WORKDIR /app + +# Copy the binary +COPY --from=build /go/bin/app /app/himbot + +# Copy migrations directory +COPY --from=build /app/migrations /app/migrations # Set the entrypoint -ENTRYPOINT ["/app"] +ENTRYPOINT ["/app/himbot"] diff --git a/docker-compose.yml b/docker-compose.yml index 04bbeb4..cf9cf81 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -30,4 +30,4 @@ services: - HIMBOARD_COOLDOWN_SECONDS=${HIMBOARD_COOLDOWN_SECONDS:-5} - SENDBUCKS_COOLDOWN_SECONDS=${SENDBUCKS_COOLDOWN_SECONDS:-1800} volumes: - - ${ROOT_DIR}/himbot_data:/data + - ${ROOT_DIR}:/data diff --git a/env.example b/env.example new file mode 100644 index 0000000..0a0ec41 --- /dev/null +++ b/env.example @@ -0,0 +1,29 @@ +# Discord Configuration +DISCORD_TOKEN=your_discord_bot_token_here + +# Docker Configuration +IMAGE=your_image_name:latest +ROOT_DIR=./himbot_data + +# Himbucks System Configuration (optional - defaults provided) +# HIMBUCKS_PER_REWARD=10 +# MESSAGE_COUNT_THRESHOLD=5 +# HIMBUCKS_COOLDOWN_MINUTES=1 + +# Markov Chain Configuration (optional - defaults provided) +# MARKOV_DEFAULT_MESSAGES=100 +# MARKOV_MAX_MESSAGES=1000 +# MARKOV_CACHE_SIZE=10 + +# Database Configuration (optional - defaults provided) +# DB_MAX_OPEN_CONNS=25 +# DB_MAX_IDLE_CONNS=5 +# DB_CONN_MAX_LIFETIME_MINUTES=5 + +# Command Cooldowns in seconds (optional - defaults provided) +# PING_COOLDOWN_SECONDS=5 +# HS_COOLDOWN_SECONDS=10 +# MARKOV_COOLDOWN_SECONDS=30 +# HIMBUCKS_COOLDOWN_SECONDS=5 +# HIMBOARD_COOLDOWN_SECONDS=5 +# SENDBUCKS_COOLDOWN_SECONDS=1800 \ No newline at end of file