Skip to content

Commit

Permalink
Update Dockerfiles to include debricked scan command as entrypoint
Browse files Browse the repository at this point in the history
  • Loading branch information
emilwareus committed Jan 25, 2024
1 parent bf0238e commit d1a72f1
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
19 changes: 10 additions & 9 deletions build/docker/alpine.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ COPY go.mod go.sum ./
RUN go mod download && go mod verify
COPY . .
RUN mkdir -p internal/file/embedded && \
wget -O internal/file/embedded/supported_formats.json https://debricked.com/api/1.0/open/files/supported-formats
wget -O internal/file/embedded/supported_formats.json https://debricked.com/api/1.0/open/files/supported-formats
RUN go build -o debricked ./cmd/debricked
ENTRYPOINT ["debricked"]

Expand Down Expand Up @@ -57,18 +57,19 @@ RUN dotnet --version && npm -v && yarn -v
RUN npm install --global bower && bower -v

RUN apk add --no-cache \
git \
php82 \
php82-curl \
php82-mbstring \
php82-openssl \
php82-phar
git \
php82 \
php82-curl \
php82-mbstring \
php82-openssl \
php82-phar

RUN apk add --no-cache --virtual build-dependencies curl && \
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/bin --filename=composer \
&& apk del build-dependencies
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/bin --filename=composer \
&& apk del build-dependencies

RUN php -v && composer --version

# Put copy at the end to speedup Docker build by caching previous RUNs and run those concurrently
COPY --from=dev /cli/debricked /usr/bin/debricked
ENTRYPOINT [ "debricked", "scan" ]
1 change: 1 addition & 0 deletions build/docker/debian.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -106,3 +106,4 @@ RUN php -v && composer --version

# Put copy at the end to speedup Docker build by caching previous RUNs and run those concurrently
COPY --from=dev /cli/debricked /usr/bin/debricked
ENTRYPOINT [ "debricked", "scan" ]

0 comments on commit d1a72f1

Please sign in to comment.