Add docker
This commit is contained in:
parent
7241455afd
commit
b9e58d77fd
14
Dockerfile
Normal file
14
Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
FROM clojure:temurin-8-lein-bookworm-slim
|
||||
|
||||
# set work directory
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
# set time
|
||||
RUN ln -fs /usr/share/zoneinfo/Europe/Madrid /etc/localtime
|
||||
RUN dpkg-reconfigure -f noninteractive tzdata
|
||||
|
||||
# Install make
|
||||
RUN apt update -y
|
||||
RUN apt install -y make
|
||||
|
||||
Entrypoint ["make", "run"]
|
4
Makefile
4
Makefile
@ -1,5 +1,9 @@
|
||||
.DEFAULT_GOAL := build
|
||||
|
||||
run:
|
||||
lein run
|
||||
while :; do echo 'Hit CTRL+C'; sleep 1; done
|
||||
|
||||
build:
|
||||
make check
|
||||
lein codox
|
||||
|
13
compose.yaml
Normal file
13
compose.yaml
Normal file
@ -0,0 +1,13 @@
|
||||
services:
|
||||
importart-stories-alert-for-hacker-news:
|
||||
restart: always
|
||||
build:
|
||||
context: .
|
||||
dockerfile: Dockerfile
|
||||
image: clojure:temurin-8-lein-bookworm-slim
|
||||
volumes:
|
||||
- ./Makefile:/usr/src/app/Makefile
|
||||
- ./isahn_history.json:/usr/src/app/isahn_history.json
|
||||
- ./config.edn:/usr/src/app/config.edn
|
||||
- ./src/:/usr/src/app/src/
|
||||
- ./project.clj:/usr/src/app/project.clj
|
@ -1,6 +0,0 @@
|
||||
{
|
||||
:min_score 600
|
||||
:chat "@important_stories_alert_hacknews"
|
||||
:bot_token "bot918542948:AAGNfvZ3yqGkainRc-OFB44AYF7yYjY2TuM"
|
||||
:run_every_miliseconds 3600000
|
||||
}
|
1
isahn_history.json
Normal file
1
isahn_history.json
Normal file
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user