Support Center

(Linux) Installing the JumpCloud Agent using Ansible

The following playbook can be used to install the agent onto an Ansible-managed server:

- hosts: all
  sudo: yes

  tasks:
    - name: Install curl package (Debian based)
      action: apt pkg='curl' state=installed
      when: "'$ansible_pkg_mgr' == 'apt'"
    
    - name: Install curl package (RedHat based)
      action: yum name='curl' state=installed
      when: "'$ansible_pkg_mgr' == 'yum'"

    - name: Check if JumpCloud is already installed
      shell: "[ -d /opt/jc ] && echo 'Found' || echo ''"
      register: jc_installed

    - name: Update time
      shell: "ntpdate -u pool.ntp.org"
      when: "not jc_installed.stdout"

    - name: Install JumpCloud
      shell: "curl --header 'x-connect-key: REDACTED' https://kickstart.jumpcloud.com/Kickstart | sudo bash"
      when: "not jc_installed.stdout"
 
Third-party Ansible roles:

https://github.com/shrikeh/ansible-jumpcloud
 

Last Updated: Sep 12, 2017 09:59AM MDT

Related Articles
desk-forwarding@jumpcloud.com
https://cdn.desk.com/
false
desk
Loading
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
about
false
Invalid characters found
/customer/en/portal/articles/autocomplete