0

I have got two kubernetes containers.

  • maxmind container
  • application container

I need the maxmind container to download the database and share the same with the second container. The below is my yaml file and I am unable to make it work

containers:

    - name: maxmind
      image: maxmindinc/geoipupdate
      env:
      - name: GEOIPUPDATE_ACCOUNT_ID
        value: '12345' 
      - name: GEOIPUPDATE_LICENSE_KEY
        value: xyz
      - name: GEOIPUPDATE_EDITION_IDS
        value: GeoLite2-ASN GeoLite2-City GeoLite2-Country
      volumeMounts:            
        - name: geoip-db
          mountPath: /usr/local/share/GeoIP

    - image: app
      imagePullPolicy: Always
      name: app     
      volumeMounts:
      - name: app
        mountPath: /var/www/html
      - name: geoip-db
        mountPath: /var/www/html/var/cache/ip_data/      
  volumes:
    - name: app
      persistentVolumeClaim:
        claimName: app-pv-claim
    - name: geoip-db
      emptyDir: {}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.