Commit ce17205a by John Jarvis

Merge pull request #989 from edx/jarv/rabbit-from-deb

Jarv/rabbit from deb
parents 4116ebfa e668c6ba
- name: Deploy rabbitmq - name: Deploy rabbitmq
hosts: all hosts: all
sudo: True sudo: True
gather_facts: False # The rabbitmq role depends on
# ansible_default_ipv4 so
# gather_facts must be set to True
gather_facts: True
roles: roles:
- aws - aws
- rabbitmq - rabbitmq
...@@ -28,9 +28,15 @@ rabbitmq_refresh: false ...@@ -28,9 +28,15 @@ rabbitmq_refresh: false
rabbitmq_apt_key: "http://www.rabbitmq.com/rabbitmq-signing-key-public.asc" rabbitmq_apt_key: "http://www.rabbitmq.com/rabbitmq-signing-key-public.asc"
rabbitmq_repository: "deb http://www.rabbitmq.com/debian/ testing main" rabbitmq_repository: "deb http://www.rabbitmq.com/debian/ testing main"
# We mirror the deb package for rabbitmq-server because
# nodes need to be running the same version
rabbitmq_pkg_url: "http://files.edx.org/rabbitmq_packages/rabbitmq-server_3.2.3-1_all.deb"
rabbitmq_pkg: "rabbitmq-server" rabbitmq_pkg: "rabbitmq-server"
rabbitmq_debian_pkgs: rabbitmq_debian_pkgs:
- python-software-properties - python-software-properties
# for installing the deb package with
# dependencies
- gdebi
rabbitmq_config_dir: "/etc/rabbitmq" rabbitmq_config_dir: "/etc/rabbitmq"
rabbitmq_cookie_dir: "/var/lib/rabbitmq" rabbitmq_cookie_dir: "/var/lib/rabbitmq"
......
...@@ -10,10 +10,17 @@ ...@@ -10,10 +10,17 @@
apt: pkg={{",".join(rabbitmq_debian_pkgs)}} state=present apt: pkg={{",".join(rabbitmq_debian_pkgs)}} state=present
- name: add rabbit repository - name: add rabbit repository
apt_repository: repo="{{rabbitmq_repository}}" state=present apt_repository: repo="{{rabbitmq_repository}}" state=present update_cache=yes
- name: install rabbitmq - name: fetch the rabbitmq server deb
apt: pkg={{rabbitmq_pkg}} state=present update_cache=yes get_url: >
url={{ rabbitmq_pkg_url }}
dest=/var/tmp/{{ rabbitmq_pkg_url|basename }}
- name: install rabbit package using gdebi
shell: >
gdebi --n {{ rabbitmq_pkg_url|basename }}
chdir=/var/tmp
- name: stop rabbit cluster - name: stop rabbit cluster
service: name=rabbitmq-server state=stopped service: name=rabbitmq-server state=stopped
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment