Skip to content

Commit

Permalink
fix CIS-DI-0001
Browse files Browse the repository at this point in the history
fix CIS-DI-0005
  • Loading branch information
SQLHorizons committed Aug 31, 2021
1 parent 48b0488 commit 70fb287
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 0 additions & 2 deletions .github/containerscan/allowedlist.yaml
Expand Up @@ -10,8 +10,6 @@ general:

bestPracticeViolations:
- DKL-DI-0005
- CIS-DI-0001
- DKL-DI-0003
- CIS-DI-0005
- CIS-DI-0006
- CIS-DI-0008
9 changes: 7 additions & 2 deletions Dockerfile
Expand Up @@ -16,7 +16,9 @@ ENV AZP_POOL=Default \

# To make it easier for build and release pipelines to run apt-get,
# configure apt to not require confirmation (assume the -y argument by default)
RUN echo "APT::Get::Assume-Yes \"true\";" > /etc/apt/apt.conf.d/90assumeyes
RUN export DOCKER_CONTENT_TRUST=1 && \
echo "APT::Get::Assume-Yes \"true\";" > /etc/apt/apt.conf.d/90assumeyes && \
groupadd -rg 1050 adoagent && useradd -rms /bin/bash -u 1050 -g adoagent adoagent

SHELL ["pwsh", "-command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]

Expand Down Expand Up @@ -45,6 +47,9 @@ RUN apt-get update && \
WORKDIR /azp

COPY ./scripts/start-docker.sh .
RUN chmod +x start-docker.sh
RUN chmod +x start-docker.sh && \
chown -Rv adoagent:adoagent start-docker.sh

USER adoagent

CMD ["/azp/start-docker.sh"]

0 comments on commit 70fb287

Please sign in to comment.