2020-09-16 14:05:51 +00:00
|
|
|
#! Copyright 2020 the Pinniped contributors. All Rights Reserved.
|
2020-09-10 02:06:39 +00:00
|
|
|
#! SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
|
|
|
#@ load("@ytt:data", "data")
|
|
|
|
|
|
|
|
---
|
|
|
|
apiVersion: v1
|
|
|
|
kind: Namespace
|
|
|
|
metadata:
|
2020-09-10 22:20:02 +00:00
|
|
|
name: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
labels:
|
2020-09-10 22:20:02 +00:00
|
|
|
name: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
---
|
|
|
|
apiVersion: v1
|
|
|
|
kind: ServiceAccount
|
|
|
|
metadata:
|
2020-09-10 22:20:02 +00:00
|
|
|
name: local-user-authenticator-service-account
|
|
|
|
namespace: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
---
|
2020-09-17 23:07:31 +00:00
|
|
|
#@ if data.values.image_pull_dockerconfigjson and data.values.image_pull_dockerconfigjson != "":
|
|
|
|
apiVersion: v1
|
|
|
|
kind: Secret
|
|
|
|
metadata:
|
|
|
|
name: image-pull-secret
|
|
|
|
namespace: local-user-authenticator
|
|
|
|
labels:
|
|
|
|
app: local-user-authenticator
|
|
|
|
type: kubernetes.io/dockerconfigjson
|
|
|
|
data:
|
|
|
|
.dockerconfigjson: #@ data.values.image_pull_dockerconfigjson
|
|
|
|
#@ end
|
|
|
|
---
|
2020-09-10 02:06:39 +00:00
|
|
|
apiVersion: apps/v1
|
|
|
|
kind: Deployment
|
|
|
|
metadata:
|
2020-09-10 22:20:02 +00:00
|
|
|
name: local-user-authenticator
|
|
|
|
namespace: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
labels:
|
2020-09-10 22:20:02 +00:00
|
|
|
app: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
spec:
|
|
|
|
replicas: 1
|
|
|
|
selector:
|
|
|
|
matchLabels:
|
2020-09-10 22:20:02 +00:00
|
|
|
app: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
template:
|
|
|
|
metadata:
|
|
|
|
labels:
|
2020-09-10 22:20:02 +00:00
|
|
|
app: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
spec:
|
2020-09-10 22:20:02 +00:00
|
|
|
serviceAccountName: local-user-authenticator-service-account
|
2020-09-17 23:07:31 +00:00
|
|
|
#@ if data.values.image_pull_dockerconfigjson and data.values.image_pull_dockerconfigjson != "":
|
|
|
|
imagePullSecrets:
|
|
|
|
- name: image-pull-secret
|
|
|
|
#@ end
|
2020-09-10 02:06:39 +00:00
|
|
|
containers:
|
2020-09-10 22:20:02 +00:00
|
|
|
- name: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
#@ if data.values.image_digest:
|
|
|
|
image: #@ data.values.image_repo + "@" + data.values.image_digest
|
|
|
|
#@ else:
|
|
|
|
image: #@ data.values.image_repo + ":" + data.values.image_tag
|
|
|
|
#@ end
|
|
|
|
imagePullPolicy: IfNotPresent
|
|
|
|
command: #! override the default entrypoint
|
2020-09-10 22:20:02 +00:00
|
|
|
- /usr/local/bin/local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
---
|
|
|
|
apiVersion: v1
|
|
|
|
kind: Service
|
|
|
|
metadata:
|
2020-09-10 22:20:02 +00:00
|
|
|
name: local-user-authenticator
|
|
|
|
namespace: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
labels:
|
2020-09-10 22:20:02 +00:00
|
|
|
app: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
spec:
|
|
|
|
type: ClusterIP
|
|
|
|
selector:
|
2020-09-10 22:20:02 +00:00
|
|
|
app: local-user-authenticator
|
2020-09-10 02:06:39 +00:00
|
|
|
ports:
|
|
|
|
- protocol: TCP
|
|
|
|
port: 443
|
|
|
|
targetPort: 443
|