apiVersion: apps/v1
kind: Deployment
metadata:
  name: truck-kun-music-player-deployment
  labels:
    app: truck-kun-music-player
spec:
  replicas: 1
  selector:
    matchLabels:
      app: truck-kun-music-player
  template:
    metadata:
      labels:
        app: truck-kun-music-player
    spec:
      containers:
        - name: truck-kun-music-player
          image: aveliz/truck-kun:musicPlayer-1.0.0
          imagePullPolicy: "Always"
          ports:
            - containerPort: 80
          env:
            - name: NODE_ENV
              value: "production"
          volumeMounts:
            - name: discord-config
              mountPath: /app/config/discord.json
              subPath: discord.json
            - name: youtube-config
              mountPath: /app/config/youtube.json
              subPath: youtube.json
      volumes:
        - name: discord-config
          configMap:
            name: truck-kun-discord-config-music-player
        - name: youtube-config
          configMap:
            name: truck-kun-youtube-config
