mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-25 09:08:45 +05:00
Update ansible scripts to allow updating go when is neccesary
This commit is contained in:
committed by
Dan Christian Bogos
parent
80c2a7ac59
commit
b678433fd2
@@ -18,6 +18,7 @@
|
||||
changed_when: false
|
||||
|
||||
- name: Remove old installation of Go
|
||||
become: yes
|
||||
file:
|
||||
path: /usr/local/go
|
||||
state: absent
|
||||
@@ -76,7 +77,7 @@
|
||||
insertafter: last
|
||||
|
||||
- name: Add GOROOT to PATH for root
|
||||
become: yes
|
||||
become: yes
|
||||
lineinfile:
|
||||
dest: ~/.bashrc
|
||||
line: export PATH=$PATH:$GOROOT/bin
|
||||
@@ -88,7 +89,7 @@
|
||||
dest: ~/.bashrc
|
||||
line: export GOPATH='{{ golang_gopath }}'
|
||||
insertafter: last
|
||||
|
||||
|
||||
- name: Add GOPATH to PATH for root
|
||||
become: yes
|
||||
lineinfile:
|
||||
@@ -113,9 +114,9 @@
|
||||
dest: ~/.bashrc
|
||||
line: export GOPATH='{{ golang_gopath }}'
|
||||
insertafter: last
|
||||
|
||||
|
||||
- name: Add GOPATH to PATH
|
||||
lineinfile:
|
||||
dest: ~/.bashrc
|
||||
line: export PATH=$PATH:$GOPATH/bin
|
||||
insertafter: last
|
||||
insertafter: last
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
###############################################################
|
||||
# Go language SDK version number
|
||||
golang_version: '1.13'
|
||||
go_version_target: "go version go{{ golang_version }} linux/amd64"
|
||||
# Mirror to download the Go language SDK redistributable package from
|
||||
golang_mirror: 'https://storage.googleapis.com/golang'
|
||||
# Base installation directory the Go language SDK distribution
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
changed_when: false
|
||||
|
||||
- name: Remove old installation of Go
|
||||
become: yes
|
||||
file:
|
||||
path: /usr/local/go
|
||||
state: absent
|
||||
@@ -76,7 +77,7 @@
|
||||
insertafter: last
|
||||
|
||||
- name: Add GOROOT to PATH for root
|
||||
become: yes
|
||||
become: yes
|
||||
lineinfile:
|
||||
dest: ~/.bashrc
|
||||
line: export PATH=$PATH:$GOROOT/bin
|
||||
@@ -88,7 +89,7 @@
|
||||
dest: ~/.bashrc
|
||||
line: export GOPATH='{{ golang_gopath }}'
|
||||
insertafter: last
|
||||
|
||||
|
||||
- name: Add GOPATH to PATH for root
|
||||
become: yes
|
||||
lineinfile:
|
||||
@@ -113,9 +114,9 @@
|
||||
dest: ~/.bashrc
|
||||
line: export GOPATH='{{ golang_gopath }}'
|
||||
insertafter: last
|
||||
|
||||
|
||||
- name: Add GOPATH to PATH
|
||||
lineinfile:
|
||||
dest: ~/.bashrc
|
||||
line: export PATH=$PATH:$GOPATH/bin
|
||||
insertafter: last
|
||||
insertafter: last
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
###############################################################
|
||||
# Go language SDK version number
|
||||
golang_version: '1.13'
|
||||
go_version_target: "go version go{{ golang_version }} linux/amd64"
|
||||
# Mirror to download the Go language SDK redistributable package from
|
||||
golang_mirror: 'https://storage.googleapis.com/golang'
|
||||
# Base installation directory the Go language SDK distribution
|
||||
@@ -28,7 +29,7 @@
|
||||
kafka_download_folder: "/home/{{ kafka_user }}/Downloads"
|
||||
kafka_install_folder: "/home/{{ kafka_user }}"
|
||||
# kafka_user_password: "123456y"
|
||||
|
||||
|
||||
###############################################################
|
||||
# CGRateS location
|
||||
cgrates_dir: "{{ golang_gopath }}/src/github.com/cgrates/cgrates"
|
||||
@@ -40,9 +41,9 @@
|
||||
|
||||
###########################################################################################################################
|
||||
# install dependencies
|
||||
- name: Install build-essential
|
||||
- name: Install build-essential
|
||||
apt:
|
||||
name: build-essential
|
||||
name: build-essential
|
||||
state: present
|
||||
|
||||
- name: Install the git
|
||||
@@ -142,4 +143,3 @@
|
||||
command: 'sh {{ cgrates_dir }}/data/storage/mongo/setup_cgr_db.sh'
|
||||
args:
|
||||
chdir: '{{ cgrates_dir }}/data/storage/mongo/'
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
changed_when: false
|
||||
|
||||
- name: Remove old installation of Go
|
||||
become: yes
|
||||
file:
|
||||
path: /usr/local/go
|
||||
state: absent
|
||||
@@ -76,7 +77,7 @@
|
||||
insertafter: last
|
||||
|
||||
- name: Add GOROOT to PATH for root
|
||||
become: yes
|
||||
become: yes
|
||||
lineinfile:
|
||||
dest: ~/.bashrc
|
||||
line: export PATH=$PATH:$GOROOT/bin
|
||||
@@ -88,7 +89,7 @@
|
||||
dest: ~/.bashrc
|
||||
line: export GOPATH='{{ golang_gopath }}'
|
||||
insertafter: last
|
||||
|
||||
|
||||
- name: Add GOPATH to PATH for root
|
||||
become: yes
|
||||
lineinfile:
|
||||
@@ -113,9 +114,9 @@
|
||||
dest: ~/.bashrc
|
||||
line: export GOPATH='{{ golang_gopath }}'
|
||||
insertafter: last
|
||||
|
||||
|
||||
- name: Add GOPATH to PATH
|
||||
lineinfile:
|
||||
dest: ~/.bashrc
|
||||
line: export PATH=$PATH:$GOPATH/bin
|
||||
insertafter: last
|
||||
insertafter: last
|
||||
|
||||
Reference in New Issue
Block a user