Compare commits
20 Commits
a9fbe72fa4
...
cdc0f990b4
Author | SHA1 | Date |
---|---|---|
Gabriele De Rosa | cdc0f990b4 | |
Gabriele De Rosa | 39fc0be135 | |
Gabriele De Rosa | f4caa7a924 | |
Gabriele De Rosa | 6cbbd6d1b3 | |
Gabriele De Rosa | 35de8e84c6 | |
Gabriele De Rosa | b1ba5cf3f2 | |
Gabriele De Rosa | 6352e9df70 | |
Gabriele De Rosa | 487d77e90e | |
Gabriele De Rosa | 30f1023f6c | |
Gabriele De Rosa | f43e4c38da | |
Gabriele De Rosa | ffc7c78315 | |
Gabriele De Rosa | 22da4ff0ea | |
Gabriele De Rosa | 857d89d26a | |
Gabriele De Rosa | 33326e3a5b | |
Gabriele De Rosa | c08169e987 | |
Gabriele De Rosa | 2cdaf9199e | |
Gabriele De Rosa | f8c09f7eb7 | |
Gabriele De Rosa | b73cde8cd5 | |
Gabriele De Rosa | b468bf8572 | |
Gabriele De Rosa | a336ea0ffa |
|
@ -98,7 +98,7 @@ jobs:
|
||||||
uses: docker/build-push-action@v2
|
uses: docker/build-push-action@v2
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
platforms: linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v6
|
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
@ -155,7 +155,7 @@ jobs:
|
||||||
uses: docker/build-push-action@v2
|
uses: docker/build-push-action@v2
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
platforms: linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v6
|
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
34
Dockerfile
34
Dockerfile
|
@ -1,26 +1,38 @@
|
||||||
FROM python:3
|
FROM alpine:3.14
|
||||||
|
|
||||||
# Set working space
|
# Set working space
|
||||||
WORKDIR /usr/src/app
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
RUN apt-get update \
|
RUN apk update --no-cache \
|
||||||
# Prevent endless waiting
|
# Install packages
|
||||||
&& DEBIAN_FRONTEND=noninteractive \
|
&& apk add --no-cache \
|
||||||
|
tzdata \
|
||||||
|
python3 py3-pip py3-numpy py3-pandas py3-matplotlib \
|
||||||
|
ttf-liberation qt5-qtwebkit wkhtmltopdf \
|
||||||
# Set UTC as timezone
|
# Set UTC as timezone
|
||||||
&& ln -snf /usr/share/zoneinfo/Europe/Rome /etc/localtime \
|
&& ln -snf /usr/share/zoneinfo/Europe/Rome /etc/localtime \
|
||||||
# Install APT packages
|
|
||||||
&& apt-get install -y --fix-missing wkhtmltopdf \
|
|
||||||
# Remove tmp files
|
# Remove tmp files
|
||||||
&& apt-get clean && rm -rf /tmp/* /var/tmp/* \
|
&& rm -rf /tmp/* /var/tmp/* \
|
||||||
# Add PiWheels support
|
|
||||||
&& echo "[global]\nextra-index-url=https://www.piwheels.org/simple" >> /etc/pip.conf \
|
|
||||||
# Upgrade PIP
|
# Upgrade PIP
|
||||||
&& python3 -m pip install --no-cache-dir --upgrade pip
|
&& python3 -m pip install --no-cache-dir --upgrade pip
|
||||||
|
|
||||||
# Copy and install requirements
|
# Copy PIP extra index URLs
|
||||||
|
COPY pip.conf .
|
||||||
|
|
||||||
|
# Copy requirements
|
||||||
COPY requirements.txt .
|
COPY requirements.txt .
|
||||||
RUN python3 -m pip install -r requirements.txt
|
|
||||||
|
# Install requirements
|
||||||
|
RUN apk update --no-cache \
|
||||||
|
# Install tmp packages
|
||||||
|
&& apk add --no-cache --virtual build-deps gcc python3-dev musl-dev build-base freetype-dev libpng-dev openblas-dev \
|
||||||
|
# Add PIP extra index URLs
|
||||||
|
&& mv pip.conf /etc/pip.conf \
|
||||||
|
# Install PIP packages
|
||||||
|
&& python3 -m pip install --no-cache-dir -r requirements.txt \
|
||||||
|
# Delete tmp packages
|
||||||
|
&& apk del build-deps
|
||||||
|
|
||||||
# Copy app
|
# Copy app
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
28
README.md
28
README.md
|
@ -1,23 +1,29 @@
|
||||||
|
|
||||||
|
<h1 align="center">:it: ITA vs. COVID :microbe:</h1>
|
||||||
|
<p align="center">
|
||||||
|
<img src="./assets/images/logo.png" alt="header" width="150px">
|
||||||
|
</p>
|
||||||
|
<h3 align="center">Un bot telegram che ti aggiorna sulla battaglia contro il Covid in Italia</h3>
|
||||||
|
<p align="center">
|
||||||
|
<a href="https://hub.docker.com/r/derogab/itavscovidbot">
|
||||||
|
<img src="https://img.shields.io/docker/pulls/derogab/itavscovidbot?label=Downloads&logo=docker" alt="Docker Pulls">
|
||||||
|
</a>
|
||||||
|
<a href="https://github.com/derogab/itavscovidbot/actions/workflows/docker-publish.yml">
|
||||||
|
<img src="https://github.com/derogab/itavscovidbot/actions/workflows/docker-publish.yml/badge.svg" alt="Build & Push Docker Image">
|
||||||
|
</a>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
|
||||||
<div align="center">
|
## Configurazione
|
||||||
<img src="./assets/images/logo.png" width="150">
|
|
||||||
</div>
|
|
||||||
<div align="center">
|
|
||||||
<h1 align="center">🇮🇹 ITA vs. COVID 🦠</h1>
|
|
||||||
Un bot telegram che ti aggiorna sulla battaglia contro il Covid in Italia.
|
|
||||||
</div>
|
|
||||||
|
|
||||||
### Configurazione
|
|
||||||
Copia tutti i file `.env.sample` nei relativi `.env` con le preferenze personali.
|
Copia tutti i file `.env.sample` nei relativi `.env` con le preferenze personali.
|
||||||
|
|
||||||
### Avvio
|
## Avvio
|
||||||
Il bot utilizza [docker](https://www.docker.com/) e [docker-compose](https://docs.docker.com/compose).
|
Il bot utilizza [docker](https://www.docker.com/) e [docker-compose](https://docs.docker.com/compose).
|
||||||
```
|
```
|
||||||
docker-compose up --build
|
docker-compose up --build
|
||||||
```
|
```
|
||||||
|
|
||||||
### Crediti
|
## Crediti
|
||||||
|
|
||||||
Il bot è stato sviluppato da [@derogab](https://github.com/derogab) e il codice sorgente è pubblicamente disponibile su Github.
|
Il bot è stato sviluppato da [@derogab](https://github.com/derogab) e il codice sorgente è pubblicamente disponibile su Github.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue