简体   繁体   中英

ansible module for EKS cluster

i'm trying to automate deployment in eks cluster using k8s ansible module. It's seem that k8s module doesn't support EKS.

does anyone have an example of managing objects in eks using k8s ansible module.

Thanks in advance.

Thanks everyone, for your comments, it finally works.

I just reconfigure the file ~/.kube/kubeconfig and set the good config in ~/.aws/ .

Snippet of the Ansible task:

- name: "deploy app"
  k8s:
    kubeconfig: "{{ kube_config }}"
    namespace: "default"
    state: "present"
    src: "{{ item }}"
  with_items:
    - "{{ data_dir }}/{{ instance_name }}/deployment/deployment_file_1.yml"
    - "{{ data_dir }}/{{ instance_name }}/deployment/deployment_file_2.yml"
    - "{{ data_dir }}/{{ instance_name }}/deployment/deployment_file_3.yml"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM