feat: pkg docker
This commit is contained in:
parent
eb1bb8fbbc
commit
f24edf9800
3 changed files with 33 additions and 0 deletions
4
.env_sample
Normal file
4
.env_sample
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
export FTEST_AUTH="foobar"
|
||||||
|
export FTEST_HOST="http://ftest.example.org"
|
||||||
|
export FTEST_TARGET_HOST="http://localhost:3000"
|
||||||
|
export FTEST_USER="john@example.org"
|
16
Dockerfile
Normal file
16
Dockerfile
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
FROM python
|
||||||
|
|
||||||
|
LABEL org.opencontainers.image.source https://git.batsense.net/ForgeFlux/ap-test
|
||||||
|
|
||||||
|
RUN useradd -ms /bin/bash -u 1001 ap
|
||||||
|
RUN apt-get update && apt-get install -y ca-certificates git
|
||||||
|
WORKDIR /src/
|
||||||
|
COPY requirements.txt .
|
||||||
|
RUN pip install -r requirements.txt
|
||||||
|
|
||||||
|
USER ap
|
||||||
|
WORKDIR /home/ap
|
||||||
|
RUN mkdir app/
|
||||||
|
WORKDIR /home/ap/app/
|
||||||
|
COPY . .
|
||||||
|
CMD [ "behave"]
|
13
Makefile
Normal file
13
Makefile
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
lint:
|
||||||
|
black ./common/ ./features/
|
||||||
|
|
||||||
|
docker.build:
|
||||||
|
docker buildx build -t forgeflux/ap-test --load .
|
||||||
|
|
||||||
|
docker.run:
|
||||||
|
docker run \
|
||||||
|
--network=ftest \
|
||||||
|
-e FTEST_AUTH=${FTEST_AUTH} \
|
||||||
|
-e FTEST_HOST=${FTEST_HOST} \
|
||||||
|
-e FTEST_TARGET_HOST=${FTEST_TARGET_HOST} \
|
||||||
|
-e FTEST_USER=${FTEST_USER} forgeflux/ap-test
|
Loading…
Reference in a new issue