Skip to content

Commit

Permalink
update Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
gertd committed Oct 9, 2021
1 parent 1ee640b commit 5ef24c1
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 72 deletions.
13 changes: 2 additions & 11 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,8 @@ RUN apk add --no-cache bash
WORKDIR /app
COPY --from=build /src/dist/build_linux_amd64/policy /app/

COPY ./scripts/login.sh /app/login.sh
RUN chmod +x /app/login.sh

COPY ./scripts/logout.sh /app/logout.sh
RUN chmod +x /app/logout.sh

COPY ./scripts/build.sh /app/build.sh
RUN chmod +x /app/build.sh

COPY ./scripts/push.sh /app/push.sh
RUN chmod +x /app/push.sh
COPY --from=build /src/scripts /app/
RUN chmod +x /app/*.sh

ENV POLICY_FILE_STORE_ROOT=/github/workspace/_policy

Expand Down
2 changes: 0 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ go 1.16
// replace github.com/aserto-dev/aserto-runtime => ../aserto-runtime

require (
github.com/Microsoft/go-winio v0.5.0 // indirect
github.com/Microsoft/hcsshim v0.8.20 // indirect
github.com/alecthomas/kong v0.2.17
github.com/aserto-dev/aserto-runtime v0.0.24-0.20210902103415-12e69833e705
Expand All @@ -21,7 +20,6 @@ require (
github.com/docker/libtrust v0.0.0-20160708172513-aabc10ec26b7 // indirect
github.com/dustin/go-humanize v1.0.0
github.com/golang/snappy v0.0.4-0.20210608040537-544b4180ac70 // indirect
github.com/google/go-cmp v0.5.6 // indirect
github.com/google/go-containerregistry v0.6.0
github.com/google/uuid v1.3.0
github.com/google/wire v0.5.0
Expand Down
6 changes: 1 addition & 5 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,6 @@ github.com/aserto-dev/aserto-runtime v0.0.24-0.20210902103415-12e69833e705 h1:kx
github.com/aserto-dev/aserto-runtime v0.0.24-0.20210902103415-12e69833e705/go.mod h1:7Y8y0Mq8fwnf3anJnINxqK+ffh5KMzwzt+/qO5EM4D0=
github.com/aserto-dev/clui v0.0.1/go.mod h1:rk87XJefw6Pp8ef3nTirzMVTDE0g2BWojwAZy3cC/TY=
github.com/aserto-dev/clui v0.1.1/go.mod h1:rk87XJefw6Pp8ef3nTirzMVTDE0g2BWojwAZy3cC/TY=
github.com/aserto-dev/clui v0.1.3 h1:vnc4DJgMWyon8vDspg1aRwERlXpEKEJBdKaZ5/Uj53k=
github.com/aserto-dev/clui v0.1.3/go.mod h1:mXYK1s48N0bAfpThOZvGfXk0bwehNHAzE5UxeJ/8q6c=
github.com/aserto-dev/clui v0.1.4 h1:1hD2SKQkHNYC6KPJPo4D/0h/GgTyODqlpbgoMrIBXm8=
github.com/aserto-dev/clui v0.1.4/go.mod h1:mXYK1s48N0bAfpThOZvGfXk0bwehNHAzE5UxeJ/8q6c=
github.com/aserto-dev/go-utils v0.0.8 h1:mwfjMEHNFImFDvVTUK0oubEj4oyB6g6bfujCh6sy6+U=
Expand Down Expand Up @@ -226,6 +224,7 @@ github.com/containerd/imgcrypt v1.1.1/go.mod h1:xpLnwiQmEUJPvQoAapeb2SNCxz7Xr6PJ
github.com/containerd/nri v0.0.0-20201007170849-eb1350a75164/go.mod h1:+2wGSDGFYfE5+So4M5syatU0N0f0LbWpuqyMi4/BE8c=
github.com/containerd/nri v0.0.0-20210316161719-dbaa18c31c14/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
github.com/containerd/nri v0.1.0/go.mod h1:lmxnXF6oMkbqs39FiCt1s0R2HSMhcLel9vNL3m4AaeY=
github.com/containerd/stargz-snapshotter/estargz v0.7.0 h1:1d/rydzTywc76lnjJb6qbPCiTiCwts49AzKps/Ecblw=
github.com/containerd/stargz-snapshotter/estargz v0.7.0/go.mod h1:83VWDqHnurTKliEB0YvWMiCfLDwv4Cjj1X9Vk98GJZw=
github.com/containerd/ttrpc v0.0.0-20190828154514-0e0f228740de/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
github.com/containerd/ttrpc v0.0.0-20190828172938-92c8520ef9f8/go.mod h1:PvCDdDGpgqzQIzDW1TphrGLssLDZp2GuS+X5DkEJB8o=
Expand Down Expand Up @@ -455,7 +454,6 @@ github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLe
github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
github.com/google/subcommands v1.0.1 h1:/eqq+otEXm5vhfBrbREPCSVQbvofip6kIz+mX5TUH7k=
github.com/google/subcommands v1.0.1/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk=
github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
Expand Down Expand Up @@ -953,7 +951,6 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.3.1-0.20200828183125-ce943fd02449/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.2 h1:Gz96sIWK3OalVv/I/qNygP42zyoKp3xptRVCWRFEBvo=
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
Expand Down Expand Up @@ -1212,7 +1209,6 @@ golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4f
golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0=
golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.5 h1:ouewzE6p+/VEB31YYnTbEJdi8pFqKp4P4n85vwo3DHA=
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
Expand Down
2 changes: 1 addition & 1 deletion scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ CMD="/app/policy build ${SRC_PATH} --tag ${INPUT_TAG} --verbosity=${VERBOSITY}"
eval "$CMD" || e_code=1
printf "\n"

if [ "${VERBOSITY}" -ge "2" ]; then
if [ "${VERBOSITY}" -ge "1" ]; then
/app/policy images
printf "\n"
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts/pull.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ CMD="/app/policy pull ${INPUT_TAG} --verbosity=${VERBOSITY}"
eval "$CMD" || e_code=1
printf "\n"

if [ "${VERBOSITY}" -ge "2" ]; then
if [ "${VERBOSITY}" -ge "1" ]; then
/app/policy images
printf "\n"
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts/push.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ CMD="/app/policy push ${INPUT_TAG} --verbosity=${VERBOSITY}"
eval "$CMD" || e_code=1
printf "\n"

if [ "${VERBOSITY}" -ge "2" ]; then
if [ "${VERBOSITY}" -ge "1" ]; then
/app/policy images --remote
printf "\n"
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts/rm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ CMD="/app/policy rm ${INPUT_TAG} --verbosity=${VERBOSITY}"
eval "$CMD" || e_code=1
printf "\n"

if [ "${VERBOSITY}" -ge "2" ]; then
if [ "${VERBOSITY}" -ge "1" ]; then
/app/policy images
printf "\n"
fi
Expand Down
50 changes: 0 additions & 50 deletions scripts/test.sh

This file was deleted.

0 comments on commit 5ef24c1

Please sign in to comment.