mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-15 05:09:54 +05:00
splitted in devel/release
This commit is contained in:
2
data/vagrant/Vagrantfile
vendored
2
data/vagrant/Vagrantfile
vendored
@@ -54,7 +54,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
|
||||
# View the documentation for the provider you're using for more
|
||||
# information on available options.
|
||||
config.vm.provision "ansible" do |ansible|
|
||||
ansible.playbook = "ansible_golang_release.yml"
|
||||
ansible.playbook = "cgrates_release.yml"
|
||||
#ansible.verbose = "vvvv"
|
||||
end
|
||||
end
|
||||
|
||||
@@ -110,6 +110,6 @@ if ! shopt -oq posix; then
|
||||
fi
|
||||
|
||||
export GOROOT=$HOME/go
|
||||
export GOPATH=$HOME/go_home
|
||||
export GOPATH=$HOME/code
|
||||
|
||||
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin
|
||||
|
||||
@@ -33,23 +33,11 @@
|
||||
- freeswitch-meta-vanilla
|
||||
- freeswitch-mod-json-cdr
|
||||
|
||||
- name: add cgrates apt-key
|
||||
apt_key: url=http://apt.itsyscom.com/conf/cgrates.gpg.key state=present
|
||||
|
||||
- name: add cgrates repo
|
||||
apt_repository: repo='deb http://apt.itsyscom.com/debian wheezy main' state=present
|
||||
|
||||
- name: install cgrates
|
||||
apt: pkg=cgrates update_cache=yes state=latest
|
||||
|
||||
- name: update mysql root password for root account
|
||||
mysql_user: name=root host=localhost password={{ root_db_password }}
|
||||
|
||||
- name: copy .my.cnf
|
||||
template: src=my.cnf dest=/root/.my.cnf mode=0600
|
||||
|
||||
- name: setup database tables
|
||||
shell: chdir=/usr/share/cgrates/storage/mysql ./setup_cgr_db.sh root {{ root_db_password }} localhost
|
||||
|
||||
- hosts: all
|
||||
user: vagrant
|
||||
@@ -68,4 +56,14 @@
|
||||
copy: src=bashrc dest=~/.bashrc
|
||||
|
||||
- name: get cgrates
|
||||
shell: GOROOT=~/go GOPATH=~/go_home ~/go/bin/go get -u -v github.com/cgrates/cgrates
|
||||
shell: GOROOT=~/go GOPATH=~/code ~/go/bin/go get -u -v github.com/cgrates/cgrates
|
||||
|
||||
- name: create a link to data dir
|
||||
file: src=~/code/src/github.com/cgrates/cgrates/data dest=/usr/share/cgrates state=symlink
|
||||
|
||||
- name: setup database tables
|
||||
shell: chdir=/usr/share/cgrates/storage/mysql ./setup_cgr_db.sh root {{ root_db_password }} localhost
|
||||
|
||||
- name: create link to cgrates dir
|
||||
file: src=~/code/src/github.com/cgrates/cgrates dest=~/cgr state=symlink
|
||||
|
||||
51
data/vagrant/cgrates_release.yml
Normal file
51
data/vagrant/cgrates_release.yml
Normal file
@@ -0,0 +1,51 @@
|
||||
---
|
||||
|
||||
- hosts: all
|
||||
user: vagrant
|
||||
sudo: yes
|
||||
vars:
|
||||
root_db_password: CGRateS.org
|
||||
|
||||
tasks:
|
||||
- name: install dependency
|
||||
apt: pkg={{ item }} state=latest
|
||||
with_items:
|
||||
- git
|
||||
- redis-server
|
||||
- mysql-server
|
||||
- python-mysqldb
|
||||
|
||||
- name: add freeswitch gpg key
|
||||
command: gpg --keyserver pool.sks-keyservers.net --recv-key D76EDC7725E010CF
|
||||
|
||||
- name: add freeswitch apt key
|
||||
shell: gpg -a --export D76EDC7725E010CF | sudo apt-key add -
|
||||
|
||||
- name: add freeswitch apt repo
|
||||
apt_repository: repo='deb http://files.freeswitch.org/repo/deb/debian/ wheezy main' state=present
|
||||
|
||||
- name: install freeswitch
|
||||
apt: pkg={{ item }} update_cache=yes state=latest
|
||||
with_items:
|
||||
- freeswitch-meta-vanilla
|
||||
- freeswitch-mod-json-cdr
|
||||
|
||||
- name: add cgrates apt-key
|
||||
apt_key: url=http://apt.itsyscom.com/conf/cgrates.gpg.key state=present
|
||||
|
||||
- name: add cgrates repo
|
||||
apt_repository: repo='deb http://apt.itsyscom.com/debian wheezy main' state=present
|
||||
|
||||
- name: install cgrates
|
||||
apt: pkg=cgrates update_cache=yes state=latest
|
||||
|
||||
- name: update mysql root password for root account
|
||||
mysql_user: name=root host=localhost password={{ root_db_password }}
|
||||
|
||||
- name: copy .my.cnf
|
||||
template: src=my.cnf dest=/root/.my.cnf mode=0600
|
||||
|
||||
- name: setup database tables
|
||||
shell: chdir=/usr/share/cgrates/storage/mysql ./setup_cgr_db.sh root {{ root_db_password }} localhost
|
||||
|
||||
|
||||
Reference in New Issue
Block a user