forked from kubernetes/autoscaler
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: use non-root user for base-image
There is no need to use the root user. This allows the user to comply with pod security standards. Signed-off-by: Moritz Johner <[email protected]>
- Loading branch information
Showing
2 changed files
with
4 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,9 +11,10 @@ | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
ARG BASEIMAGE=gcr.io/distroless/static:latest-amd64 | ||
ARG BASEIMAGE=gcr.io/distroless/static:nonroot-amd64 | ||
FROM $BASEIMAGE | ||
LABEL maintainer="Marcin Wielgus <[email protected]>" | ||
|
||
COPY cluster-autoscaler-amd64 /cluster-autoscaler | ||
WORKDIR / | ||
CMD ["/cluster-autoscaler"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,9 +11,10 @@ | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
ARG BASEIMAGE=gcr.io/distroless/static:latest-arm64 | ||
ARG BASEIMAGE=gcr.io/distroless/static:nonroot-arm64 | ||
FROM $BASEIMAGE | ||
LABEL maintainer="Marcin Wielgus <[email protected]>" | ||
|
||
COPY cluster-autoscaler-arm64 /cluster-autoscaler | ||
WORKDIR / | ||
CMD ["/cluster-autoscaler"] |