init: 폴더구조 설계 및 인프라 설계

This commit is contained in:
DongHyeonka
2026-07-24 14:31:53 +09:00
parent 34ad612281
commit f9c463f87a
1839 changed files with 323096 additions and 1 deletions
+15
View File
@@ -0,0 +1,15 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: docker-registry-config
data:
REGISTRY_HTTP_ADDR: "0.0.0.0:5000"
REGISTRY_LOG_FORMATTER: "json"
REGISTRY_STORAGE: "s3"
REGISTRY_STORAGE_S3_REGION: "us-east-1"
REGISTRY_STORAGE_S3_REGIONENDPOINT: "http://minio"
REGISTRY_STORAGE_S3_BUCKET: "docker-registry"
REGISTRY_STORAGE_S3_FORCEPATHSTYLE: "true"
REGISTRY_STORAGE_S3_SKIPVERIFY: "true"
REGISTRY_STORAGE_REDIRECT_DISABLE: "true"
REGISTRY_STORAGE_DELETE_ENABLED: "true"
@@ -0,0 +1,94 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: docker-registry
spec:
replicas: 1
revisionHistoryLimit: 5
progressDeadlineSeconds: 600
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 25%
maxUnavailable: 0
selector:
matchLabels:
app.kubernetes.io/name: docker-registry
app.kubernetes.io/instance: docker-registry
template:
metadata:
labels:
app.kubernetes.io/name: docker-registry
app.kubernetes.io/instance: docker-registry
spec:
serviceAccountName: docker-registry
automountServiceAccountToken: false
terminationGracePeriodSeconds: 45
securityContext:
runAsNonRoot: true
runAsUser: 10001
runAsGroup: 10001
fsGroup: 10001
fsGroupChangePolicy: OnRootMismatch
seccompProfile:
type: RuntimeDefault
containers:
- name: registry
image: registry:2.8.3
imagePullPolicy: IfNotPresent
ports:
- name: http
containerPort: 5000
protocol: TCP
envFrom:
- configMapRef:
name: docker-registry-config
- secretRef:
name: docker-registry-minio
resources:
requests:
cpu: 100m
memory: 256Mi
limits:
memory: 512Mi
startupProbe:
httpGet:
path: /v2/
port: http
periodSeconds: 5
failureThreshold: 12
timeoutSeconds: 3
readinessProbe:
httpGet:
path: /v2/
port: http
periodSeconds: 10
failureThreshold: 3
timeoutSeconds: 3
livenessProbe:
httpGet:
path: /v2/
port: http
periodSeconds: 30
failureThreshold: 3
timeoutSeconds: 3
securityContext:
runAsNonRoot: true
runAsUser: 10001
runAsGroup: 10001
allowPrivilegeEscalation: false
privileged: false
readOnlyRootFilesystem: true
capabilities:
drop:
- ALL
seccompProfile:
type: RuntimeDefault
volumeMounts:
- name: tmp
mountPath: /tmp
volumes:
- name: tmp
emptyDir:
medium: Memory
sizeLimit: 64Mi
+19
View File
@@ -0,0 +1,19 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- serviceaccount.yaml
- configmap.yaml
- service.yaml
- deployment.yaml
labels:
- pairs:
app.kubernetes.io/name: docker-registry
app.kubernetes.io/instance: docker-registry
app.kubernetes.io/version: "2.8.3"
app.kubernetes.io/component: registry
app.kubernetes.io/part-of: platform-registry
app.kubernetes.io/managed-by: kustomize
includeSelectors: false
includeTemplates: true
+15
View File
@@ -0,0 +1,15 @@
apiVersion: v1
kind: Service
metadata:
name: docker-registry
spec:
type: ClusterIP
selector:
app.kubernetes.io/name: docker-registry
app.kubernetes.io/instance: docker-registry
ports:
- name: http
port: 5000
targetPort: http
protocol: TCP
appProtocol: http
@@ -0,0 +1,5 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: docker-registry
automountServiceAccountToken: false