1
0
Fork 0

Add drone CI
continuous-integration/drone/push Build was killed Details

This commit is contained in:
nemunaire 2020-10-18 16:14:00 +02:00
parent faa5759645
commit 5ec2f2997b
2 changed files with 51 additions and 0 deletions

26
.drone.yml Normal file
View File

@ -0,0 +1,26 @@
---
kind: pipeline
type: docker
name: default
platform:
os: linux
arch: arm
steps:
- name: build
image: python:alpine
commands:
- pip install --no-cache-dir -r requirements.txt
- pip install .
- name: docker
image: plugins/docker
settings:
repo: nemunaire/nemubot
auto_tag: true
auto_tag_suffix: ${DRONE_STAGE_OS}-${DRONE_STAGE_ARCH}
username:
from_secret: docker_username
password:
from_secret: docker_password

25
Dockerfile Normal file
View File

@ -0,0 +1,25 @@
FROM python:alpine as pybuild
WORKDIR /usr/src/app
COPY requirements.txt ./
RUN apk add --no-cache bash build-base capstone-dev && \
pip install --no-cache-dir -r requirements.txt && \
pip install bs4 capstone dnspython
FROM python:alpine
RUN apk add --no-cache capstone w3m
WORKDIR /usr/src/app
VOLUME /var/lib/nemubot
COPY requirements.txt ./
COPY --from=pybuild /usr/lib/python3.9 /usr/lib/python3.9
COPY . .
ENTRYPOINT [ "python", "-m", "nemubot", "-d", "-M", "/usr/src/app/modules" ]
CMD [ "-D", "/var/lib/nemubot" ]