feat: init Docker pkg
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
c27badb81c
commit
97b1c04036
3 changed files with 37 additions and 0 deletions
3
.dockerignore
Normal file
3
.dockerignore
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
venv/
|
||||||
|
.env
|
||||||
|
nodeinfo.log
|
20
.woodpecker.yml
Normal file
20
.woodpecker.yml
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
pipeline:
|
||||||
|
build_docker_img:
|
||||||
|
image: plugins/docker
|
||||||
|
when:
|
||||||
|
event: [pull_request]
|
||||||
|
settings:
|
||||||
|
dry_run: true
|
||||||
|
repo: forgeflux/nodeinfo-test
|
||||||
|
tags: latest
|
||||||
|
|
||||||
|
build_and_publish_docker_img:
|
||||||
|
image: plugins/docker
|
||||||
|
when:
|
||||||
|
event: [push, tag, deployment]
|
||||||
|
settings:
|
||||||
|
username: forgeflux
|
||||||
|
password:
|
||||||
|
from_secret: DOCKER_TOKEN
|
||||||
|
repo: forgeflux/nodeinfo-test
|
||||||
|
tags: latest
|
14
Dockerfile
Normal file
14
Dockerfile
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
FROM python
|
||||||
|
|
||||||
|
LABEL org.opencontainers.image.source https://git.batsense.net/ForgeFlux/nodeinfo-test
|
||||||
|
|
||||||
|
RUN useradd -ms /bin/bash -u 1001 nodeinfo
|
||||||
|
RUN apt-get update && apt-get install -y ca-certificates git
|
||||||
|
|
||||||
|
USER nodeinfo
|
||||||
|
WORKDIR /home/nodeinfo
|
||||||
|
RUN mkdir app/
|
||||||
|
WORKDIR /home/nodeinfo/app/
|
||||||
|
COPY . .
|
||||||
|
RUN pip install -r requirements.txt
|
||||||
|
CMD [ "python3", "run.py"]
|
Loading…
Reference in a new issue