Dockerfile
This commit is contained in:
parent
95826b4a3d
commit
0925bffad8
21
.gitea/workflows/container.yml
Normal file
21
.gitea/workflows/container.yml
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
name: Build container
|
||||||
|
|
||||||
|
on:
|
||||||
|
push
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
Package-Python:
|
||||||
|
uses: jmaa/workflows/.gitea/workflows/python-package.yaml@v6.03
|
||||||
|
secrets:
|
||||||
|
PIPY_REPO_USER: ${{ secrets.PIPY_REPO_USER }}
|
||||||
|
PIPY_REPO_PASS: ${{ secrets.PIPY_REPO_PASS }}
|
||||||
|
Package-Container:
|
||||||
|
uses: jmaa/workflows/.gitea/workflows/container.yaml@v6.03
|
||||||
|
secrets:
|
||||||
|
DOCKER_USERNAME: ${{ secrets.PIPY_REPO_USER }}
|
||||||
|
DOCKER_PASSWORD: ${{ secrets.PIPY_REPO_PASS }}
|
||||||
|
PIPELINE_WORKER_SSH_KEY: ${{ secrets.PIPELINE_WORKER_SSH_KEY }}
|
||||||
|
PIPELINE_WORKER_KNOWN_HOSTS: ${{ secrets.PIPELINE_WORKER_KNOWN_HOSTS }}
|
||||||
|
with:
|
||||||
|
DOCKER_REG_DOMAIN: gitfub.space
|
||||||
|
DOCKER_ORG: jmaasoft
|
|
@ -1,9 +0,0 @@
|
||||||
name: Python Package
|
|
||||||
on: [push]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
Package:
|
|
||||||
uses: jmaa/workflows/.gitea/workflows/python-package.yaml@v6.02
|
|
||||||
secrets:
|
|
||||||
PIPY_REPO_USER: ${{ secrets.PIPY_REPO_USER }}
|
|
||||||
PIPY_REPO_PASS: ${{ secrets.PIPY_REPO_PASS }}
|
|
28
Dockerfile
Normal file
28
Dockerfile
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
# Dependencies
|
||||||
|
FROM python:alpine
|
||||||
|
RUN pip install -U \
|
||||||
|
pip \
|
||||||
|
setuptools \
|
||||||
|
wheel
|
||||||
|
|
||||||
|
WORKDIR /personal_data
|
||||||
|
|
||||||
|
RUN adduser -S personal_data && chown personal_data /personal_data
|
||||||
|
#debian: RUN useradd -m -r personal_data && chown personal_data /personal_data
|
||||||
|
|
||||||
|
# Requirements
|
||||||
|
ADD requirements.txt requirements.txt
|
||||||
|
ADD private_deps private_deps
|
||||||
|
RUN pip install --no-cache-dir -r requirements.txt
|
||||||
|
RUN pip install --no-cache-dir --no-index --find-links=private_deps private_deps/*
|
||||||
|
|
||||||
|
# Tracability
|
||||||
|
ARG GIT_HASH
|
||||||
|
ENV GIT_HASH=${GIT_HASH:-dev}
|
||||||
|
|
||||||
|
# Code
|
||||||
|
ADD personal_data personal_data
|
||||||
|
|
||||||
|
USER personal_data
|
||||||
|
|
||||||
|
CMD python -m personal_data
|
Loading…
Reference in New Issue
Block a user