This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

librarian-ansible integrated using patch.

  • Loading branch information...
actionjack committed Apr 8, 2015
1 parent 4b6f50f commit 7547ac0d35ade272c5c7ddc3b5dded5209f7edf7
Showing with 83 additions and 1,527 deletions.
  1. +3 −0 .gitignore
  2. +2 −0 .librarian/ansible/config
  3. +12 −0 Ansiblefile
  4. +50 −0 Ansiblefile.lock
  5. +7 −0 Gemfile.lock
  6. +5 −1 README.md
  7. +2 −1 globals.yml
  8. 0 {roles → roles-static}/docker_server/README.md
  9. 0 {roles/docker_server → roles-static/gandalf}/meta/main.yml
  10. 0 {roles/gandalf → roles-static/hipache}/README.md
  11. 0 {roles/gandalf → roles-static/hipache}/meta/main.yml
  12. +0 −79 roles/bennojoy.redis/README.md
  13. +0 −31 roles/bennojoy.redis/defaults/main.yml
  14. +0 −26 roles/bennojoy.redis/files/epel6.repo
  15. +0 −26 roles/bennojoy.redis/files/epel7.repo
  16. +0 −6 roles/bennojoy.redis/handlers/main.yml
  17. +0 −1 roles/bennojoy.redis/meta/.galaxy_install_info
  18. +0 −27 roles/bennojoy.redis/meta/main.yml
  19. +0 −43 roles/bennojoy.redis/tasks/main.yml
  20. +0 −440 roles/bennojoy.redis/templates/redis.conf.j2
  21. +0 −3 roles/bennojoy.redis/templates/rsyslogd.conf.j2
  22. +0 −4 roles/bennojoy.redis/vars/Debian.yml
  23. +0 −2 roles/bennojoy.redis/vars/RedHat.yml
  24. +0 −14 roles/bennojoy.redis/vars/main.yml
  25. +0 −4 roles/docker_server/defaults/main.yml
  26. +0 −5 roles/docker_server/handlers/main.yml
  27. +0 −20 roles/docker_server/tasks/main.yml
  28. +0 −6 roles/docker_server/vars/main.yml
  29. +0 −4 roles/gandalf/defaults/main.yml
  30. +0 −8 roles/gandalf/handlers/main.yml
  31. +0 −46 roles/gandalf/tasks/main.yml
  32. +0 −6 roles/gandalf/templates/archive-server.j2
  33. +0 −37 roles/gandalf/templates/gandalf.conf.j2
  34. +0 −9 roles/gandalf/vars/main.yml
  35. +0 −38 roles/hipache/README.md
  36. +0 −4 roles/hipache/defaults/main.yml
  37. +0 −10 roles/hipache/files/hipache.upstart
  38. +0 −5 roles/hipache/handlers/main.yml
  39. +0 −128 roles/hipache/meta/main.yml
  40. +0 −30 roles/hipache/tasks/main.yml
  41. +0 −16 roles/hipache/templates/hipache.conf.j2
  42. +0 −6 roles/hipache/vars/main.yml
  43. +0 −38 roles/tsuru_api/README.md
  44. +0 −8 roles/tsuru_api/defaults/main.yml
  45. +0 −5 roles/tsuru_api/handlers/main.yml
  46. +0 −128 roles/tsuru_api/meta/main.yml
  47. +0 −44 roles/tsuru_api/tasks/main.yml
  48. +0 −3 roles/tsuru_api/templates/tsuru-server.j2
  49. +0 −204 roles/tsuru_api/templates/tsuru.conf.j2
  50. +0 −9 roles/tsuru_api/vars/main.yml
  51. +2 −2 site.yml
View
@@ -1,2 +1,5 @@
inventory.vagrant
.vagrant/
.idea
roles/*
tmp
@@ -0,0 +1,2 @@
---
LIBRARIAN_ANSIBLE_PATH: roles
View
@@ -0,0 +1,12 @@
#!/usr/bin/env ruby
#^syntax detection
site "https://galaxy.ansible.com/api/v1"
role "aalda.docker-registry", "1.0.3"
role "DavidWittman.redis", "1.0.3"
role "docker_server", path: "./roles-static/docker_server"
role "gandalf", path: "./roles-static/gandalf"
role "greendayonfire.mongodb", "1.2.1"
role "hipache", path: "./roles-static/hipache"
role "tsuru_api", path: "./roles-static/tsuru_api"
View
@@ -0,0 +1,50 @@
GIT
remote: https://github.com/DavidWittman/ansible-redis
ref: master
sha: fa99c66aa9a2b976c8a762f23681d78825921f02
specs:
DavidWittman.redis (1.0.3)
GIT
remote: https://github.com/UnderGreen/ansible-role-mongodb
ref: master
sha: 8f1bb3f3ed23388ca5709449cbc8820dd66014d8
specs:
greendayonfire.mongodb (1.2.1)
GIT
remote: https://github.com/codingbunch/ansible-docker-registry
ref: master
sha: 33ff3ce7acd57f22b9b6bda67856be78d1e7930e
specs:
aalda.docker-registry (1.0.3)
PATH
remote: ./roles-static/docker_server
specs:
docker_server (0.0.0)
PATH
remote: ./roles-static/gandalf
specs:
gandalf (0.0.0)
PATH
remote: ./roles-static/hipache
specs:
hipache (0.0.0)
PATH
remote: ./roles-static/tsuru_api
specs:
tsuru_api (0.0.0)
DEPENDENCIES
DavidWittman.redis (= 1.0.3)
aalda.docker-registry (= 1.0.3)
docker_server (>= 0)
gandalf (>= 0)
greendayonfire.mongodb (= 1.2.1)
hipache (>= 0)
tsuru_api (>= 0)
View
@@ -0,0 +1,7 @@
GEM
specs:
PLATFORMS
ruby
DEPENDENCIES
View
@@ -3,14 +3,18 @@
Ansible based project to configure a multi-node tsuru cluster.
### Requirement:
* ansible 1.4 or higher.
* ansible 1.8 or higher.
### Instructions:
* Update the inventory file to reflect the infrastructure that you want to use for your tsuru cluster.
> Note: can be any number of nodes, but every section in the inventory file has to have at least one node.
> (it is possible to use a node in more that one section).
* Install or update ansible playbooks using [librarian-ansible](https://github.com/bcoe/librarian-ansible):
```{r, engine='bash'}
librarian-ansible install
```
* Configure the ssh key used to access the nodes:
```{r, engine='bash'}
ssh-add <the-public-ssh-key-file>
View
@@ -14,8 +14,9 @@ docker_port: 4243
gandalf_host: "{{ hostvars[groups['gandalf'][0]].external_ip }}"
gandalf_port: 8080
mongodb_conf_bind_ip: "0.0.0.0"
mongodb_host: "{{ hostvars[groups['mongodb'][0]].internal_ip }}"
mongodb_port: 27017
admin_user: administrator@gds.tsuru.gov
admin_password: admin123
admin_password: admin123
File renamed without changes.
File renamed without changes.
@@ -1,79 +0,0 @@
redis
=====
This role helps to deploy a Redis master or replication server on target host.
This roles sets several default values for Redis configuration which can be
overrriden by the user.
Requirements
------------
This role requires Ansible 1.4 or higher, and platform requirements are listed
in the metadata file.
Role Variables
--------------
The variables that can be passed to this role and a brief description about
them are as follows. See the documentation for Redis for details:
redis_bind_address # The network address for redis to bind to
redis_port: 6379 # Port for redis server
redis_syslog_enabled: "yes" # enable_syslog
redis_databases: 16 # Set number of databases
redis_database_save_times: # Save the DB on disk (seconds changes)
- [900, 1]
- [300, 10]
- [60, 10000]
redis_dbfilename: dump.rdb # Filename for the db
redis_db_dir: /var/lib/redis # DB directory
redis_role: master # The role for this redis deployment (master/slave)
redis_requirepass: false # If password is required for querying
redis_pass: None # Password if require_pass is enabled
redis_max_clients: 128
redis_max_memory: 512mb
redis_maxmemory_policy: volatile-lru
redis_appendfsync: everysec # How often to sync the filesystem
# If redis_role is "slave", set these values too
redis_master_ip: 1.1.1.1 # The master's IP
redis_master_port: 6379 # master port
redis_master_auth: None # master auth
Examples
--------
The following example sets up a master Redis server.
- hosts: all
sudo: true
roles:
- {role: bennojoy.redis, redis_port: 11244}
The following example sets up a slave Redis server.
- hosts: all
sudo: true
roles:
- {role: bennojoy.redis,
redis_role: 'slave',
master_ip: '192.168.2.10',
master_auth: 'foobar'}
Dependencies
------------
None
License
-------
BSD
Author Information
------------------
Benno Joy
@@ -1,31 +0,0 @@
---
redis_bind_address: "0.0.0.0"
redis_port: 6379
redis_syslog_enabled: "yes"
# Must be USER or between LOCAL0-LOCAL7.
redis_syslog_facility: "local0"
redis_logfile: /var/log/redis.log
redis_databases: 16
redis_database_save_times:
- [900, 1]
- [300, 10]
- [60, 10000]
redis_dbfilename: dump.rdb
redis_db_dir: /var/lib/redis
redis_role: master
redis_requirepass: false
redis_pass: None
redis_max_clients: 128
redis_max_memory: 512mb
redis_maxmemory_policy: volatile-lru
redis_appendfsync: everysec
# check https://www.kernel.org/doc/Documentation/sysctl/vm.txt
# and http://redis.io/topics/faq
redis_overcommit_memory: 1
#If role is slave set these values too
redis_master_ip: 1.1.1.1
redis_master_port: 6379
redis_master_auth: None
@@ -1,26 +0,0 @@
[epel]
name=Extra Packages for Enterprise Linux 6 - $basearch
baseurl=http://download.fedoraproject.org/pub/epel/6/$basearch
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=$basearch
failovermethod=priority
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
[epel-debuginfo]
name=Extra Packages for Enterprise Linux 6 - $basearch - Debug
#baseurl=http://download.fedoraproject.org/pub/epel/6/$basearch/debug
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-debug-6&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
gpgcheck=1
[epel-source]
name=Extra Packages for Enterprise Linux 6 - $basearch - Source
#baseurl=http://download.fedoraproject.org/pub/epel/6/SRPMS
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-source-6&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
gpgcheck=1
@@ -1,26 +0,0 @@
[epel]
name=Extra Packages for Enterprise Linux 7 - $basearch
#baseurl=http://download.fedoraproject.org/pub/epel/7/$basearch
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch
failovermethod=priority
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
[epel-debuginfo]
name=Extra Packages for Enterprise Linux 7 - $basearch - Debug
#baseurl=http://download.fedoraproject.org/pub/epel/7/$basearch/debug
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-debug-7&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
gpgcheck=1
[epel-source]
name=Extra Packages for Enterprise Linux 7 - $basearch - Source
#baseurl=http://download.fedoraproject.org/pub/epel/7/SRPMS
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-source-7&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
gpgcheck=1
@@ -1,6 +0,0 @@
---
- name: restart redis
service: name={{ redis_service }} state=restarted
- name: restart rsyslog
service: name=rsyslog state=restarted
@@ -1 +0,0 @@
{install_date: 'Tue Mar 24 12:06:13 2015', version: master}
@@ -1,27 +0,0 @@
---
galaxy_info:
author: "Benno Joy"
company: AnsibleWorks
license: BSD
min_ansible_version: 1.4
platforms:
- name: EL
versions:
- 6
- 7
- name: Fedora
versions:
- 19
- 20
- 21
- rawhide
- name: Ubuntu
versions:
- precise
- quantal
- raring
- saucy
categories:
- web
dependencies: []
@@ -1,43 +0,0 @@
---
- name: Add the OS specific varibles
include_vars: "{{ ansible_os_family }}.yml"
- name: Install the epel packages
yum: name=http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm state=present
when: ansible_os_family == "RedHat" and ansible_distribution != "Fedora"
and ansible_distribution_major_version == "6"
- name: Install the epel packages
yum: name=http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-1.noarch.rpm state=present
when: ansible_os_family == "RedHat" and ansible_distribution != "Fedora"
and ansible_distribution_major_version == "7"
- name: Install the Redis packages
yum: name={{ item }} state=present
with_items: redis_redhat_pkg
when: ansible_os_family == "RedHat"
- name: Install the Redis packages
apt: name={{ item }} state=present update_cache=yes
with_items: redis_ubuntu_pkg
environment: env
when: ansible_os_family == "Debian"
- name: Copy the redis configuration file
template: src=redis.conf.j2 dest={{ redis_conf_dest }}
notify:
- restart redis
- name: Copy the rsyslogd configuration file for redis filter
template: src=rsyslogd.conf.j2 dest=/etc/rsyslog.d/redis.conf
when: redis_syslog_enabled == "yes"
notify:
- restart rsyslog
- name: Set the kernel paramter for vm overcommit
sysctl: name=vm.overcommit_memory value={{ redis_overcommit_memory }} state=present
- name: start the redis service
service: name={{ redis_service }} state=started enabled=yes
Oops, something went wrong.

0 comments on commit 7547ac0

Please sign in to comment.