---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: crawler
  labels:
    app: search_engine
    component: crawler
spec:
  replicas: 3
  selector:
    matchLabels:
      app: search_engine
      component: crawler
  template:
    metadata:
      name: crawler
      labels:
        app: search_engine
        component: crawler
    spec:
      containers:
      - image: gogen120/crawler:latest
        name: crawler
        env:
        - name: MONGO
          value: mongodb
        - name: MONGO_PORT
          value: "27017"
        - name: RMQ_HOST
          value: rabbitmq
        - name: RMQ_QUEUE
          value: queue
        - name: RMQ_USERNAME
          value: crawler
        - name: RMQ_PASSWORD
          value: crawler_password
        - name: CHECK_INTERVAL
          value: "5"
        - name: EXCLUDE_URLS
          value: '.*github.com'
