Skip to content
This repository was archived by the owner on Mar 11, 2020. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions config/deploy_hosts.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ def redis_host
def worker_hosts
@hash['worker_hosts']
end

def logstreamer_port
@hash['logstreamer_port']
end
end

CONF_FILE = File.expand_path('deploy_hosts.yml', File.dirname(__FILE__))
Expand Down
1 change: 1 addition & 0 deletions lib/capistrano/tasks/kochiku.cap
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ namespace :kochiku do
kochiku_web_server_protocol: #{HostSettings.kochiku_web_protocol}
build_strategy: build_all
redis_host: #{HostSettings.redis_host}
logstreamer_port: #{HostSettings.logstreamer_port}
END
upload! StringIO.new(config), release_path.join("config/kochiku-worker.yml")
end
Expand Down
18 changes: 18 additions & 0 deletions lib/capistrano/tasks/logstreamer.cap
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
namespace :deploy do

desc 'Build Log Streamer Go files'
task :build_log_streamer do
on roles(:all) do
commands = [
"cd #{release_path}/logstreamer",
"export GOPATH=$(pwd)",
"go get github.com/julienschmidt/httprouter",
"go get github.com/stretchr/testify/assert",
"make"
]
execute commands.join(' && ')
end
end

before :publishing, :build_log_streamer
end