Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Commit

Permalink
Merge pull request #129 from nanliu/pluginsync
Browse files Browse the repository at this point in the history
Update from Intelsdi-x pluginsync 0.1.14
  • Loading branch information
nanliu authored Apr 12, 2017
2 parents 840be21 + 2322496 commit 1fbee9c
Show file tree
Hide file tree
Showing 11 changed files with 36 additions and 30 deletions.
2 changes: 1 addition & 1 deletion .pluginsync.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# File managed by pluginsync
pluginsync_config: '0.1.13'
pluginsync_config: '0.1.14'
managed_files:
- .github
- .github/ISSUE_TEMPLATE.md
Expand Down
8 changes: 2 additions & 6 deletions .sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
matrix:
- TEST_TYPE=small
- TEST_TYPE=medium
- SNAP_VERSION: latest
TEST_TYPE: large
- SNAP_VERSION: latest_build
TEST_TYPE: large
matrix:
Expand All @@ -25,9 +27,3 @@
env: SNAP_VERSION=latest TEST_TYPE=large
- go: 1.7.x
env: SNAP_VERSION=latest_build TEST_TYPE=large
deploy:
access_key_id: AKIAINMB43VSSPFZISAA
secret_access_key:
secure: K2AnEm2FcP0wEQ1rWJzkASpLUBHeICjwFxYGiq44HB3KTj/4G4MYtSIxYjWdG9C81sfCbC+wMHyWla8rRrVOxeMTBeJpoBNoX8wo3gAwetfA3DkVyN51xTsiHUa7yhjDjxD9scrGsJlwO+d9zyk63RU9rQGKxoDudlBvtfEat+Uke6Oq0rcUSXzqBF9ejLwscLYlFTmz+NfeACcvVqsB1Ht5RpR/VuqFXwpfmj/G+3YBx6RYQQempltL+JZUzT8UhHpQJf2sp148i/T/jqM4Agwmu398G61Jeu3t7ESDnvA37t+1hmmDq88AOveEp3pbOThCS/4ycbL2DRRns6aQnrZgBbVvHxY/ZdSWsyjVbqBQJCguo4BF0hyDdnfSi8mbkwcRf9XSSftwHxW0NyWPYhg/GASf2lKsrGG7UGZoUmMgb/jJ03sEdwjqzB+ICDa+Txhhmikxgwqfj0hyDXbHYmPNSwQ5TYI35upiEj8X8fERceFYgKGUCmphqsKtZq4iPcdKqJ4xBtHmKLutk2YqkDuKPUrx96/3kSTTF8OfaSU3+bipFcOyo48TLc/QEaag4MRoPU+L47xRwlSrZFFFrioVmFjxgY8yOoN0yRuc9XccMmmEzApa621OlzMjyduMw8UG5/+tXcmOOlcM1n2p+RqtJ/Vi0/9oyG7AxeP4mj8=
api_key:
secure: BxPzO6z768C2Sc6lijoRJNhMiL+HnUfcLWXB99WVQM++OaY+3t98EjabETvPfgCfl3gxyBrTnfn3umuj3dbFCSspptY+mnI/sjvvu3yfHMOPOGT+5yhPzBir+WA5GN4gAlAwvOoMYTUJf//An7b4Pa+98Tz52MJMtYvNPTtHmG8K4G6xhWRtkuIRp7jMrBJpp27RHBW03csBcX+wYwaPjTtRev4/VhnbQxquSq6EYWSXlxBPNt24y2zQJ5qcFs50XEz6FVzXp9S4rN9ngVbCHfdmwM/JxJCoeKgjDJErVb8VISNUHUHTin+4vtAU4ypheyWzxNcpGeCIECd7eNSwXFoCAZlmJIORDiWX3BlE7Hjxn+J3h0hw2EkOt6B/ReaY0fdg88xWZCGgUYiXTt4EQ7h0XugpQjTme/3w0efWufikwvgJi7EG1ITKTmTwvh8ps8IkU9WigIqcTacTLE051EIVhVsiUZJsuGgIdhQ3d3XCGS500GxNifrTxovOu2l0D3DKXoMbzt9quDHWSU28iJZsnAaYAKGt1M4rvahuC0KQ2d64Qcy4qIzoFc2O2FY9xqZGYAn0h0uPdzCgBj9FoHu3D/YEUDM7XTTws0hVT94/HpDcCiqd4zuE95cD0fHCjQfCWOBf9qMxbKWTAyHslMGtTwlIFL1IaAjLNpyI3SI=
19 changes: 10 additions & 9 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ env:
matrix:
- TEST_TYPE=small
- TEST_TYPE=medium
- SNAP_VERSION: latest
TEST_TYPE: large
- SNAP_VERSION: latest_build
TEST_TYPE: large
- TEST_TYPE=build
Expand All @@ -39,7 +41,8 @@ before_deploy:
- "./scripts/pre_deploy.sh"
deploy:
- provider: s3
access_key_id: AKIAINMB43VSSPFZISAA
access_key_id: $AWS_ACCESS_KEY_ID
secret_access_key: $AWS_SECRET_ACCESS_KEY
secret_access_key:
secure: K2AnEm2FcP0wEQ1rWJzkASpLUBHeICjwFxYGiq44HB3KTj/4G4MYtSIxYjWdG9C81sfCbC+wMHyWla8rRrVOxeMTBeJpoBNoX8wo3gAwetfA3DkVyN51xTsiHUa7yhjDjxD9scrGsJlwO+d9zyk63RU9rQGKxoDudlBvtfEat+Uke6Oq0rcUSXzqBF9ejLwscLYlFTmz+NfeACcvVqsB1Ht5RpR/VuqFXwpfmj/G+3YBx6RYQQempltL+JZUzT8UhHpQJf2sp148i/T/jqM4Agwmu398G61Jeu3t7ESDnvA37t+1hmmDq88AOveEp3pbOThCS/4ycbL2DRRns6aQnrZgBbVvHxY/ZdSWsyjVbqBQJCguo4BF0hyDdnfSi8mbkwcRf9XSSftwHxW0NyWPYhg/GASf2lKsrGG7UGZoUmMgb/jJ03sEdwjqzB+ICDa+Txhhmikxgwqfj0hyDXbHYmPNSwQ5TYI35upiEj8X8fERceFYgKGUCmphqsKtZq4iPcdKqJ4xBtHmKLutk2YqkDuKPUrx96/3kSTTF8OfaSU3+bipFcOyo48TLc/QEaag4MRoPU+L47xRwlSrZFFFrioVmFjxgY8yOoN0yRuc9XccMmmEzApa621OlzMjyduMw8UG5/+tXcmOOlcM1n2p+RqtJ/Vi0/9oyG7AxeP4mj8=
bucket: snap.ci.snap-telemetry.io
Expand All @@ -51,11 +54,10 @@ deploy:
on:
repo: intelsdi-x/snap-plugin-publisher-influxdb
branch: master
condition: $TEST_TYPE = "build" && $TRAVIS_GO_VERSION =~ ^1\.8\.[0-9]+$
condition: $TEST_TYPE = "build" && $TRAVIS_GO_VERSION =~ ^1\.8(|\.[0-9]+)$
- provider: s3
access_key_id: AKIAINMB43VSSPFZISAA
secret_access_key:
secure: K2AnEm2FcP0wEQ1rWJzkASpLUBHeICjwFxYGiq44HB3KTj/4G4MYtSIxYjWdG9C81sfCbC+wMHyWla8rRrVOxeMTBeJpoBNoX8wo3gAwetfA3DkVyN51xTsiHUa7yhjDjxD9scrGsJlwO+d9zyk63RU9rQGKxoDudlBvtfEat+Uke6Oq0rcUSXzqBF9ejLwscLYlFTmz+NfeACcvVqsB1Ht5RpR/VuqFXwpfmj/G+3YBx6RYQQempltL+JZUzT8UhHpQJf2sp148i/T/jqM4Agwmu398G61Jeu3t7ESDnvA37t+1hmmDq88AOveEp3pbOThCS/4ycbL2DRRns6aQnrZgBbVvHxY/ZdSWsyjVbqBQJCguo4BF0hyDdnfSi8mbkwcRf9XSSftwHxW0NyWPYhg/GASf2lKsrGG7UGZoUmMgb/jJ03sEdwjqzB+ICDa+Txhhmikxgwqfj0hyDXbHYmPNSwQ5TYI35upiEj8X8fERceFYgKGUCmphqsKtZq4iPcdKqJ4xBtHmKLutk2YqkDuKPUrx96/3kSTTF8OfaSU3+bipFcOyo48TLc/QEaag4MRoPU+L47xRwlSrZFFFrioVmFjxgY8yOoN0yRuc9XccMmmEzApa621OlzMjyduMw8UG5/+tXcmOOlcM1n2p+RqtJ/Vi0/9oyG7AxeP4mj8=
access_key_id: $AWS_ACCESS_KEY_ID
secret_access_key: $AWS_SECRET_ACCESS_KEY
bucket: snap.ci.snap-telemetry.io
region: us-west-2
skip_cleanup: true
Expand All @@ -65,15 +67,14 @@ deploy:
on:
repo: intelsdi-x/snap-plugin-publisher-influxdb
tags: true
condition: $TEST_TYPE = "build" && $TRAVIS_GO_VERSION =~ ^1\.8\.[0-9]+$
condition: $TEST_TYPE = "build" && $TRAVIS_GO_VERSION =~ ^1\.8(|\.[0-9]+)$
- provider: releases
api_key:
secure: BxPzO6z768C2Sc6lijoRJNhMiL+HnUfcLWXB99WVQM++OaY+3t98EjabETvPfgCfl3gxyBrTnfn3umuj3dbFCSspptY+mnI/sjvvu3yfHMOPOGT+5yhPzBir+WA5GN4gAlAwvOoMYTUJf//An7b4Pa+98Tz52MJMtYvNPTtHmG8K4G6xhWRtkuIRp7jMrBJpp27RHBW03csBcX+wYwaPjTtRev4/VhnbQxquSq6EYWSXlxBPNt24y2zQJ5qcFs50XEz6FVzXp9S4rN9ngVbCHfdmwM/JxJCoeKgjDJErVb8VISNUHUHTin+4vtAU4ypheyWzxNcpGeCIECd7eNSwXFoCAZlmJIORDiWX3BlE7Hjxn+J3h0hw2EkOt6B/ReaY0fdg88xWZCGgUYiXTt4EQ7h0XugpQjTme/3w0efWufikwvgJi7EG1ITKTmTwvh8ps8IkU9WigIqcTacTLE051EIVhVsiUZJsuGgIdhQ3d3XCGS500GxNifrTxovOu2l0D3DKXoMbzt9quDHWSU28iJZsnAaYAKGt1M4rvahuC0KQ2d64Qcy4qIzoFc2O2FY9xqZGYAn0h0uPdzCgBj9FoHu3D/YEUDM7XTTws0hVT94/HpDcCiqd4zuE95cD0fHCjQfCWOBf9qMxbKWTAyHslMGtTwlIFL1IaAjLNpyI3SI=
api_key: $GITHUB_API_KEY
file:
- release/snap-plugin-publisher-influxdb_linux_x86_64
- release/snap-plugin-publisher-influxdb_darwin_x86_64
skip_cleanup: true
on:
repo: intelsdi-x/snap-plugin-publisher-influxdb
tags: true
condition: $TEST_TYPE = "build" && $TRAVIS_GO_VERSION =~ ^1\.8\.[0-9]+$
condition: $TEST_TYPE = "build" && $TRAVIS_GO_VERSION =~ ^1\.8(|\.[0-9]+)$
2 changes: 1 addition & 1 deletion scripts/build.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# File managed by pluginsync

# http://www.apache.org/licenses/LICENSE-2.0.txt
Expand Down
2 changes: 1 addition & 1 deletion scripts/common.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# File managed by pluginsync

# http://www.apache.org/licenses/LICENSE-2.0.txt
Expand Down
2 changes: 1 addition & 1 deletion scripts/deps.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# File managed by pluginsync

# http://www.apache.org/licenses/LICENSE-2.0.txt
Expand Down
2 changes: 1 addition & 1 deletion scripts/large.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# File managed by pluginsync

set -e
Expand Down
2 changes: 1 addition & 1 deletion scripts/pre_deploy.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# File managed by pluginsync

# http://www.apache.org/licenses/LICENSE-2.0.txt
Expand Down
2 changes: 1 addition & 1 deletion scripts/test.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash
# File managed by pluginsync

# http://www.apache.org/licenses/LICENSE-2.0.txt
Expand Down
23 changes: 16 additions & 7 deletions scripts/test/large_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,21 @@
compose_yml = File.expand_path(File.join(__FILE__, "../docker-compose.yml"))
raise(Exception, "Missing docker-compose file: #{compose_yml}") unless File.exists? compose_yml

# NOTE: scan docker compose file and pull latest containers:
images = File.readlines(compose_yml).select {|l| l =~ /^\s*image:/}
images = images.collect{|l| l.split('image:').last.strip }.uniq
images.each do |i|
puts `docker pull #{i}`
end
# NOTE: scan docker compose file and pull latest containers:
images = File.readlines(compose_yml).select {|l| l =~ /^\s*image:/}
images = images.collect{|l| l.split('image:').last.strip }.uniq
images.each do |i|
puts `docker pull #{i}`
end

set :docker_compose_container, :snap

describe docker_compose(compose_yml) do

# NOTE: If you need to wait for a service or create a database perform it in setup.rb
setup = File.expand_path(File.join(__FILE__, '../setup.rb'))
eval File.read setup if File.exists? setup

its_container(:snap) do
describe 'docker-compose.yml run' do
TIMEOUT = 60
Expand Down Expand Up @@ -85,7 +90,7 @@
describe "Metrics in running tasks" do
it {
binding.pry if ENV["DEMO"] == "true"

data = curl_json_api("http://127.0.0.1:8181/v1/tasks")
task = data["body"]["ScheduledTasks"].find{|i| i['id'] == task_id}
expect(task['id']).to eq task_id
Expand Down Expand Up @@ -121,4 +126,8 @@
end
end
end

# NOTE: If you need to perform additional checks such as database verification it be done at the end:
verify = File.expand_path(File.join(__FILE__, '../verify.rb'))
eval File.read verify if File.exists? verify
end
2 changes: 1 addition & 1 deletion scripts/test/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ def load_all_plugins
c.include SnapUtils
if ENV["DEMO"] == "true" then
Pry.config.pager = false

Pry.hooks.add_hook(:before_session, "notice") do |output, binding, pry|
output.puts "Setup complete for DEMO mode. When you are finished checking out Snap please type 'exit-program' to shutdown containers."
end
Expand Down

0 comments on commit 1fbee9c

Please sign in to comment.