feat: optimize Docker image (#2398)
This commit is contained in:
9
.dockerignore
Normal file
9
.dockerignore
Normal file
@@ -0,0 +1,9 @@
|
||||
# Don't copy over git files
|
||||
.git
|
||||
.github
|
||||
.gitignore
|
||||
doc
|
||||
docs
|
||||
scripts
|
||||
test
|
||||
update-beef
|
||||
@@ -41,14 +41,11 @@ LABEL maintainer="Beef Project: github.com/beefproject/beef"
|
||||
# Create service account to run BeEF
|
||||
RUN adduser -h /beef -g beef -D beef
|
||||
|
||||
COPY . /beef
|
||||
COPY --chown=1000:1000 . /beef
|
||||
|
||||
# Use gemset created by the builder above
|
||||
COPY --from=builder /usr/local/bundle /usr/local/bundle
|
||||
|
||||
# Grant beef service account owner and groups rights over our BeEF working directory.
|
||||
RUN chown -R beef:beef /beef
|
||||
|
||||
# Install BeEF's runtime dependencies
|
||||
RUN apk add --no-cache curl git build-base openssl readline-dev zlib zlib-dev libressl-dev yaml-dev sqlite-dev sqlite libxml2-dev libxslt-dev autoconf libc6-compat ncurses automake libtool bison nodejs
|
||||
|
||||
|
||||
Reference in New Issue
Block a user