Re: Retrieving external ip in .erb template


Dmitriy Kalinin
 

Concourse release (github.com/concourse/concourse) does something like
this:
https://github.com/concourse/concourse/blob/master/jobs/atc/templates/atc_ctl.erb#L18-L39

Your example should work also.

On Fri, May 22, 2015 at 8:16 AM, Stevo Slavić <sslavic(a)gmail.com> wrote:

Hello Bosh community,

Is it possible to retrieve external ip in .erb template?

I'd like to release/deploy Apache Kafka using Bosh, and one of the
properties to configure in Kafka server.properties is advertised.host.name
- every instance needs to know it's external ip, to advertise it to others.

Should something like:

advertised.host.name=<%= spec.networks.marshal_dump.first[1].ip %>

work?

Kind regards,
Stevo Slavic.

_______________________________________________
cf-bosh mailing list
cf-bosh(a)lists.cloudfoundry.org
https://lists.cloudfoundry.org/mailman/listinfo/cf-bosh

Join cf-bosh@lists.cloudfoundry.org to automatically receive all group messages.