apiVersion: apps/v1
kind: Deployment
metadata:
  name: trips-deployment
  labels:
    app: trips-deployment
  namespace: api
spec:
  replicas: 1
  selector:
    matchLabels:
      app: trips
  template:
    metadata:
      labels:
        app: trips
    spec:
      containers:
        - name: trips
          image: registrylzk2091.azurecr.io/trips:latest
          ports:
            - containerPort: 80
          env:
            - name: SQL_USER
              value: sqladminlZk2091
            - name: SQL_PASSWORD
              valueFrom:
                secretKeyRef:
                  name: db-password-secret
                  key: password
            - name: SQL_SERVER
              value: sqlserverlzk2091.database.windows.net
            - name: SQL_DBNAME
              value: mydrivingDB


