chore: scaffold initial project with gitignore, demo app, docker setup, and requirements
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
FROM alpine:latest
|
||||
|
||||
# Install bash
|
||||
RUN apk add --no-cache bash
|
||||
|
||||
# Create non-root user
|
||||
RUN adduser -D -s /bin/bash myuser
|
||||
|
||||
# Switch to non-root user
|
||||
USER myuser
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /home/myuser
|
||||
|
||||
# Default command
|
||||
CMD ["/bin/bash"]
|
||||
@@ -0,0 +1,21 @@
|
||||
services:
|
||||
secure-bash:
|
||||
build: .
|
||||
stdin_open: true
|
||||
tty: true
|
||||
read_only: true
|
||||
tmpfs:
|
||||
- /tmp
|
||||
- /home/myuser
|
||||
cap_drop:
|
||||
- ALL
|
||||
security_opt:
|
||||
- no-new-privileges:true
|
||||
deploy:
|
||||
resources:
|
||||
limits:
|
||||
cpus: '0.5'
|
||||
memory: 128M
|
||||
reservations:
|
||||
cpus: '0.25'
|
||||
memory: 64M
|
||||
Executable
+4
@@ -0,0 +1,4 @@
|
||||
#!/usr/bin/env python3
|
||||
import os
|
||||
os.system("docker compose run secure-bash /bin/bash")
|
||||
exit(0)
|
||||
Reference in New Issue
Block a user