Closed mrdavidlaing closed 11 years ago
@dpb587 What is the correct SSH command to setup a tunnel to elasticsearch.srv-int.logsearch.cityindextest5.co.uk:9200
?
I'm currently using:
ssh -v -N -L 127.0.0.1:9200:elasticsearch.srv-int.logsearch.cityindextest5.co.uk:9200 ubuntu@redis.logsearch.cityindextest5.co.uk -i logsearch-ppe-shipper.pem -o UserKnownHostsFile=known_hosts.txt
But am unsure about the ubuntu@redis.logsearch.cityindextest5.co.uk
part
You've listed the correct SSH command. I pasted into a terminal and it seems to be working fine, are you experiencing problems?
Yes - my SSH connection from the remote CF instance keeps timing out.
Is SSH to redis.logsearch.cityindextest5.co.uk port 22 open to the world?
Hmm, you're correct. I've manually updated the security group (and confirmed from a remote host) and fixed the original cause.
Aha! That fixes it. Thx
Note to self: Procfile
should be similar to:
myweb: mono bin/myapp-web.exe -port $PORT
worker: mono bin/myapp-worker.exe
tunnel: chmod 0600 logsearch-ppe-shipper.pem && ssh -v -N -L 127.0.0.1:9200:elasticsearch.srv-int.logsearch.cityindextest5.co.uk:9200 ubuntu@redis.logsearch.cityindextest5.co.uk -i logsearch-ppe-shipper.pem -o UserKnownHostsFile=known_hosts.txt
@bitpusher - Please could you give this a code review before merging into master.
A running instance is at:
CF instance: https://api.run.pivotal.io
organization: cityindex-labs
space: development:
apps: ogsearch-purge-bot
@mrdavidlaing what addon are you using for mdproj? vs vanilla doesn't like it.
@bitpusher Hmm - it must be something native to MonoDevelop / Xamarin Studio - its the "blank" project type
Strictly speaking, all we need is some way of copying src/logsearch-ppe-ssh_tunnel/start_ssh_tunnel.rb
to the _bin
folder during project compile.
Can you think of a more ".NET" way of doing that?
@mrdavidlaing add the file to the purgebot project as content and then mark it as copy always in property box.
@bitpusher - I've integrated the script to start SSH into the PurgeBot project as suggested.
If you're happy with this, then please merge this PR
will do tonight. greasy hands right now. getting the race bikes street legal so i can go blow off some steam. don't worry, i will keep it under 260kpm. ;)
:bike:++
@bitpusher - Normally I would wait for you to merge this as the project owner, but I'm going to do it in your absence
In addition to starting
logsearch-purge-bot.exe
, a SSH tunnel should be started to give the bot container a network path into the logsearch cluster.the SSH tunnel command will be something like:
ssh -L 127.0.0.1:9200: elasticsearch.srv-int.logsearch.cityindextest5.co.uk:9200 ubuntu@logsearch.cityindextest5.co.uk
elasticSearchUrl
will then need to be set to127.0.0.1:9200
, which will route over the tunnel toelasticsearch.srv-int.logsearch.cityindextest5.co.uk:9200