Skip to content

Commit

Permalink
Merge pull request #22 from maratsh/master
Browse files Browse the repository at this point in the history
install: use "sources" option instead of wget ugly hack
  • Loading branch information
wwentland authored Sep 29, 2016
2 parents ffeb618 + 3575cf8 commit 5a2cbee
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions influxdb/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ influxdb:
system_group: 'influxdb'
system_user: 'influxdb'
toml_module: toml
use_wget_on_install: True
tmpl:
config: 'salt://influxdb/files/influxdb.config.jinja'
etc_default: 'salt://influxdb/files/influxdb.etc_default'
Expand Down
11 changes: 11 additions & 0 deletions influxdb/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
{% endif %}
{% endif %}
{% if influxdb_settings['use_wget_on_install'] == True %}
influxdb_package:
cmd.run:
- name: wget -qO /tmp/{{ filename }} {{ base_url }}/{{ filename }}
Expand All @@ -39,6 +40,7 @@ influxdb_remove_broken_download:
- onfail:
- cmd: influxdb_package
influxdb_install:
pkg.installed:
- sources:
Expand All @@ -47,6 +49,15 @@ influxdb_install:
- cmd: influxdb_package
- watch:
- cmd: influxdb_package
{% else %}
influxdb_install:
pkg.installed:
- sources:
- influxdb: {{ base_url }}/{{ filename }}
{% endif %}
influxdb_group:
group.present:
Expand Down
1 change: 1 addition & 0 deletions pillar.example
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
influxdb:
version: 0.12.0-1
no_conf_defaults: false
use_wget_on_install: True
logging:
directory: '/var/log/influxdb'
file: 'influxd.log'
Expand Down

0 comments on commit 5a2cbee

Please sign in to comment.