Merge pull request 'Building Docker image in CI and README.md update' (#1) from feature_docker into main
Reviewed-on: #1
This commit is contained in:
commit
11d12c5858
25
.drone.yml
25
.drone.yml
|
@ -7,9 +7,24 @@ steps:
|
||||||
image: 'golang:alpine'
|
image: 'golang:alpine'
|
||||||
commands:
|
commands:
|
||||||
- go build -x .
|
- go build -x .
|
||||||
|
when:
|
||||||
|
event:
|
||||||
|
- push
|
||||||
|
|
||||||
trigger:
|
- name: publish-docker
|
||||||
event:
|
image: plugins/docker
|
||||||
include:
|
settings:
|
||||||
- pull_request
|
username:
|
||||||
- push
|
from_secret: DOCKER_LOGIN
|
||||||
|
password:
|
||||||
|
from_secret: DOCKER_TOKEN
|
||||||
|
repo:
|
||||||
|
from_secret: DOCKER_REPO
|
||||||
|
tags:
|
||||||
|
- ${DRONE_TAG}
|
||||||
|
- latest
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- main
|
||||||
|
event:
|
||||||
|
- tag
|
||||||
|
|
16
Dockerfile
Normal file
16
Dockerfile
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
FROM golang:1 as builder
|
||||||
|
|
||||||
|
WORKDIR /build
|
||||||
|
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
RUN go build -o app
|
||||||
|
|
||||||
|
|
||||||
|
FROM alpine:latest
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
COPY --from=builder /build/app .
|
||||||
|
|
||||||
|
CMD ["/app/app"]
|
12
README.md
12
README.md
|
@ -1,3 +1,15 @@
|
||||||
# telegram-ollama-reply-bot
|
# telegram-ollama-reply-bot
|
||||||
|
|
||||||
[![Build Status](https://ci.skobk.in/api/badges/skobkin/telegram-ollama-reply-bot/status.svg)](https://ci.skobk.in/skobkin/telegram-ollama-reply-bot)
|
[![Build Status](https://ci.skobk.in/api/badges/skobkin/telegram-ollama-reply-bot/status.svg)](https://ci.skobk.in/skobkin/telegram-ollama-reply-bot)
|
||||||
|
|
||||||
|
# Usage
|
||||||
|
|
||||||
|
## Docker
|
||||||
|
|
||||||
|
```shell
|
||||||
|
docker run \
|
||||||
|
-e OLLAMA_TOKEN=123 \
|
||||||
|
-e OLLAMA_BASE_URL=http://ollama.tld:11434 \
|
||||||
|
-e TELEGRAM_TOKEN=12345 \
|
||||||
|
skobkin/telegram-llm-bot
|
||||||
|
```
|
||||||
|
|
Loading…
Reference in a new issue