-
Notifications
You must be signed in to change notification settings - Fork 116
Expand file tree
/
Copy pathDockerfile
More file actions
25 lines (21 loc) · 918 Bytes
/
Dockerfile
File metadata and controls
25 lines (21 loc) · 918 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# Dockerfile for kubelogin
# This Dockerfile copies a pre-built binary into a minimal scratch image.
# The binary should be built before running docker build using: make kubelogin
#
# Usage:
# make build-image # Build with latest tag
# GIT_TAG=v1.0.0 make build-image # Build with specific tag
#
FROM scratch
# Build arguments for multi-architecture support
ARG TARGETARCH=amd64
ARG VERSION=""
# OpenContainers Image Spec labels
LABEL org.opencontainers.image.source="https://github.com/Azure/kubelogin"
LABEL org.opencontainers.image.description="Kubernetes credential plugin for Azure authentication"
LABEL org.opencontainers.image.licenses="MIT"
LABEL org.opencontainers.image.version="${VERSION}"
# Copy the pre-built binary from local build to /usr/local/bin
COPY bin/linux_${TARGETARCH}/kubelogin /usr/local/bin/kubelogin
# Set the entrypoint
ENTRYPOINT ["/usr/local/bin/kubelogin"]