Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
F
flame-clmc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
flame
flame-clmc
Commits
93e8014c
Commit
93e8014c
authored
7 years ago
by
Rowan Powell
Browse files
Options
Downloads
Patches
Plain Diff
Added telegraf conf files for services, mongo and nginx install scripts, updated Vagrantfile
parent
a9f1ac3e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Vagrantfile
+77
-12
77 additions, 12 deletions
Vagrantfile
scripts/influx/telegraf_ipendpoint_template.conf
+0
-30
0 additions, 30 deletions
scripts/influx/telegraf_ipendpoint_template.conf
with
77 additions
and
42 deletions
Vagrantfile
+
77
−
12
View file @
93e8014c
...
...
@@ -25,28 +25,51 @@
# Define ipendpoint configuration parameters
ipendpoints
=
{
"
ipendpoint
1"
=>
{
"
apache
1"
=>
{
:ip_address
=>
"192.168.50.11"
,
:location
=>
"DC1"
,
:sfc_id
=>
"MS_Template_1"
,
:sfc_id_instance
=>
"MS_I1"
,
:sf_id
=>
"adaptive_streaming"
,
:sf_id_instance
=>
"adaptive_streaming_I1"
,
:ipendpoint_id
=>
"adaptive_streaming_I1_
ipendpoint
1"
,
:ipendpoint_id
=>
"adaptive_streaming_I1_
apache
1"
,
:influxdb_url
=>
"http://192.168.50.10:8086"
,
:database_name
=>
"CLMCMetrics"
},
"
ipendpoint
2"
=>
{
"
apache
2"
=>
{
:ip_address
=>
"192.168.50.12"
,
:location
=>
"DC2"
,
:sfc_id
=>
"MS_Template_1"
,
:sfc_id_instance
=>
"MS_I1"
,
:sf_id
=>
"adaptive_streaming"
,
:sf_id_instance
=>
"adaptive_streaming_I1"
,
:ipendpoint_id
=>
"adaptive_streaming_I1_ipendpoint2"
,
:ipendpoint_id
=>
"adaptive_streaming_I1_apache2"
,
:influxdb_url
=>
"http://192.168.50.10:8086"
,
:database_name
=>
"CLMCMetrics"
},
"nginx1"
=>
{
:ip_address
=>
"192.168.50.13"
,
:location
=>
"DC1"
,
:sfc_id
=>
"MS_Template_1"
,
:sfc_id_instance
=>
"MS_I1"
,
:sf_id
=>
"adaptive_streaming"
,
:sf_id_instance
=>
"adaptive_streaming_nginx_I1"
,
:ipendpoint_id
=>
"adaptive_streaming_nginx_I1_apache1"
,
:influxdb_url
=>
"http://192.168.50.10:8086"
,
:database_name
=>
"CLMCMetrics"
},
"mongo1"
=>
{
:ip_address
=>
"192.168.50.14"
,
:location
=>
"DC1"
,
:sfc_id
=>
"MS_Template_1"
,
:sfc_id_instance
=>
"MS_I1"
,
:sf_id
=>
"metadata_database"
,
:sf_id_instance
=>
"metadata_database_I1"
,
:ipendpoint_id
=>
"metadata_database_I1_apache1"
,
:influxdb_url
=>
"http://192.168.50.10:8086"
,
:database_name
=>
"CLMCMetrics"
}
}
Vagrant
.
configure
(
"2"
)
do
|
config
|
...
...
@@ -76,9 +99,9 @@ Vagrant.configure("2") do |config|
# start the CLMC service
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/start-clmc-service.sh'
end
config
.
vm
.
define
"
ipendpoint
1"
do
|
my
|
config
.
vm
.
network
:private_network
,
ip:
"
#{
ipendpoints
[
'
ipendpoint
1'
][
:ip_address
]
}
"
,
virtualbox__intnet:
"clmc-net"
# Apache Server 1
config
.
vm
.
define
"
apache
1"
do
|
my
|
config
.
vm
.
network
:private_network
,
ip:
"
#{
ipendpoints
[
'
apache
1'
][
:ip_address
]
}
"
,
virtualbox__intnet:
"clmc-net"
my
.
vm
.
provider
"virtualbox"
do
|
v
|
v
.
customize
[
"modifyvm"
,
:id
,
"--memory"
,
512
]
...
...
@@ -92,12 +115,12 @@ Vagrant.configure("2") do |config|
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/apache/install-apache.sh'
# Install CLMC agent 1
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/install-clmc-agent.sh'
,
:args
=>
"/vagrant/scripts/
influx
/telegraf_
ipendpoint
_template.conf
#{
ipendpoints
[
'
ipendpoint
1'
][
:location
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:sfc_id
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:sfc_id_instance
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:sf_id
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:sf_id_instance
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:ipendpoint_id
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:influxdb_url
]
}
#{
ipendpoints
[
'
ipendpoint
1'
][
:database_name
]
}
"
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/install-clmc-agent.sh'
,
:args
=>
"/vagrant/scripts/
apache
/telegraf_
apache
_template.conf
#{
ipendpoints
[
'
apache
1'
][
:location
]
}
#{
ipendpoints
[
'
apache
1'
][
:sfc_id
]
}
#{
ipendpoints
[
'
apache
1'
][
:sfc_id_instance
]
}
#{
ipendpoints
[
'
apache
1'
][
:sf_id
]
}
#{
ipendpoints
[
'
apache
1'
][
:sf_id_instance
]
}
#{
ipendpoints
[
'
apache
1'
][
:ipendpoint_id
]
}
#{
ipendpoints
[
'
apache
1'
][
:influxdb_url
]
}
#{
ipendpoints
[
'
apache
1'
][
:database_name
]
}
"
end
# Apache Server 2
config
.
vm
.
define
"apache2"
do
|
my
|
config
.
vm
.
define
"ipendpoint2"
do
|
my
|
config
.
vm
.
network
:private_network
,
ip:
"
#{
ipendpoints
[
'ipendpoint2'
][
:ip_address
]
}
"
,
virtualbox__intnet:
"clmc-net"
config
.
vm
.
network
:private_network
,
ip:
"
#{
ipendpoints
[
'apache2'
][
:ip_address
]
}
"
,
virtualbox__intnet:
"clmc-net"
my
.
vm
.
provider
"virtualbox"
do
|
v
|
v
.
customize
[
"modifyvm"
,
:id
,
"--memory"
,
512
]
...
...
@@ -111,6 +134,48 @@ Vagrant.configure("2") do |config|
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/apache/install-apache.sh'
# Install CLMC agent
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/install-clmc-agent.sh'
,
:args
=>
"/vagrant/scripts/influx/telegraf_ipendpoint_template.conf
#{
ipendpoints
[
'ipendpoint2'
][
:location
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:sfc_id
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:sfc_id_instance
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:sf_id
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:sf_id_instance
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:ipendpoint_id
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:influxdb_url
]
}
#{
ipendpoints
[
'ipendpoint2'
][
:database_name
]
}
"
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/install-clmc-agent.sh'
,
:args
=>
"/vagrant/scripts/apache/telegraf_apache_template.conf
#{
ipendpoints
[
'apache2'
][
:location
]
}
#{
ipendpoints
[
'apache2'
][
:sfc_id
]
}
#{
ipendpoints
[
'apache2'
][
:sfc_id_instance
]
}
#{
ipendpoints
[
'apache2'
][
:sf_id
]
}
#{
ipendpoints
[
'apache2'
][
:sf_id_instance
]
}
#{
ipendpoints
[
'apache2'
][
:ipendpoint_id
]
}
#{
ipendpoints
[
'apache2'
][
:influxdb_url
]
}
#{
ipendpoints
[
'apache2'
][
:database_name
]
}
"
end
# NGINX VM
config
.
vm
.
define
"NGINX_Service"
do
|
my
|
config
.
vm
.
network
:private_network
,
ip:
"
#{
ipendpoints
[
'nginx1'
][
:ip_address
]
}
"
,
virtualbox__intnet:
"clmc-net"
my
.
vm
.
provider
"virtualbox"
do
|
v
|
v
.
customize
[
"modifyvm"
,
:id
,
"--memory"
,
512
]
v
.
customize
[
"modifyvm"
,
:id
,
"--cpus"
,
1
]
end
# open apache port
config
.
vm
.
network
"forwarded_port"
,
guest:
80
,
host:
8081
# install the apache service
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/apache/install-nginx.sh'
# Install CLMC agent
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/install-clmc-agent.sh'
,
:args
=>
"/vagrant/scripts/nginx/telegraf_nginx_template.conf
#{
ipendpoints
[
'nginx1'
][
:location
]
}
#{
ipendpoints
[
'nginx1'
][
:sfc_id
]
}
#{
ipendpoints
[
'nginx1'
][
:sfc_id_instance
]
}
#{
ipendpoints
[
'nginx1'
][
:sf_id
]
}
#{
ipendpoints
[
'nginx1'
][
:sf_id_instance
]
}
#{
ipendpoints
[
'nginx1'
][
:ipendpoint_id
]
}
#{
ipendpoints
[
'nginx1'
][
:influxdb_url
]
}
#{
ipendpoints
[
'nginx1'
][
:database_name
]
}
"
end
# MONGODB VM
config
.
vm
.
define
"MONGO_Service"
do
|
my
|
config
.
vm
.
network
:private_network
,
ip:
"
#{
ipendpoints
[
'mongo1'
][
:ip_address
]
}
"
,
virtualbox__intnet:
"clmc-net"
my
.
vm
.
provider
"virtualbox"
do
|
v
|
v
.
customize
[
"modifyvm"
,
:id
,
"--memory"
,
512
]
v
.
customize
[
"modifyvm"
,
:id
,
"--cpus"
,
1
]
end
# open apache port
config
.
vm
.
network
"forwarded_port"
,
guest:
80
,
host:
8081
# install the apache service
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/apache/install-mongo.sh'
# Install CLMC agent
config
.
vm
.
provision
:shell
,
:path
=>
'scripts/influx/install-clmc-agent.sh'
,
:args
=>
"/vagrant/scripts/mongo/telegraf_mongo_template.conf
#{
ipendpoints
[
'mongo1'
][
:location
]
}
#{
ipendpoints
[
'mongo1'
][
:sfc_id
]
}
#{
ipendpoints
[
'mongo1'
][
:sfc_id_instance
]
}
#{
ipendpoints
[
'mongo1'
][
:sf_id
]
}
#{
ipendpoints
[
'mongo1'
][
:sf_id_instance
]
}
#{
ipendpoints
[
'mongo1'
][
:ipendpoint_id
]
}
#{
ipendpoints
[
'mongo1'
][
:influxdb_url
]
}
#{
ipendpoints
[
'mongo1'
][
:database_name
]
}
"
end
end
This diff is collapsed.
Click to expand it.
scripts/influx/telegraf_ipendpoint_template.conf
+
0
−
30
View file @
93e8014c
...
...
@@ -90,15 +90,6 @@
# user_agent = "telegraf"
# Set UDP payload size, defaults to InfluxDB UDP Client default (512 bytes)
# udp_payload = 512
[[
outputs
.
file
]]
## Files to write to, "stdout" is a specially handled file.
files
= [
"stdout"
,
"/tmp/metrics.out"
]
## Data format to output.
## Each data format has its own unique set of configuration options, read
## more about them here:
## https://github.com/influxdata/telegraf/blob/master/docs/DATA_FORMATS_OUTPUT.md
data_format
=
"influx"
###############################################################################
...
...
@@ -119,24 +110,3 @@
## MTLS
#tls_allowed_cacerts = ["/etc/telegraf/clientca.pem"]
# Read Apache status information (mod_status)
[[
inputs
.
apache
]]
## An array of URLs to gather from, must be directed at the machine
## readable version of the mod_status page including the auto query string.
## Default is "http://localhost/server-status?auto".
urls
= [
"http://localhost/server-status?auto"
]
## Credentials for basic HTTP authentication.
# username = "myuser"
# password = "mypassword"
## Maximum time to receive response.
# response_timeout = "5s"
## Optional SSL Config
# ssl_ca = "/etc/telegraf/ca.pem"
# ssl_cert = "/etc/telegraf/cert.pem"
# ssl_key = "/etc/telegraf/key.pem"
## Use SSL but skip chain & host verification
#
insecure_skip_verify
=
false
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment