Skip to content

Commit

Permalink
Ensuring 2.x is installed when no version given (#45)
Browse files Browse the repository at this point in the history
  • Loading branch information
Greg Malkov authored Jan 24, 2019
1 parent d423621 commit f0d4278
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tasks/apt_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@
state: present
update_cache: yes

- name: Ensure 2.x is installed when no version specified
set_fact:
threatstack_pkg: threatstack-agent=2*
when:
- not threatstack_v1
- threatstack_pkg == 'threatstack-agent'

- name: Ensure Threat Stack is installed.
apt:
name: "{{ threatstack_pkg }}"
Expand Down
7 changes: 7 additions & 0 deletions tasks/yum_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,13 @@
key: https://app.threatstack.com/RPM-GPG-KEY-THREATSTACK
validate_certs: no

- name: Ensure 2.x is installed when no version specified
set_fact:
threatstack_pkg: threatstack-agent-2*
when:
- not threatstack_v1
- threatstack_pkg == 'threatstack-agent'

- name: Ensure Agent is installed.
yum:
name: "{{ threatstack_pkg }}"
Expand Down

0 comments on commit f0d4278

Please sign in to comment.