fernandohackbart / bikeride-lagom

Sample Bike Ride application backend to learn Lagom
Other
4 stars 2 forks source link

Optimization for Kubernetes: Add Akka and HTTP parameters in the container build #169

Closed fernandohackbart closed 7 years ago

fernandohackbart commented 7 years ago
ENTRYPOINT /u01/authentication-lagom-impl/bin/authentication-lagom-impl \
  $(eval "echo $AUTHN_SERVICE_DEBUG")" \
  -Dhttp.address="$(eval "echo $AUTHN_SERVICE_BIND_IP")" \
  -Dhttp.port="$(eval "echo $AUTHN_SERVICE_BIND_PORT")" \
  -Dakka.remote.netty.tcp.hostname="$(eval "echo $AKKA_REMOTING_HOST")" \
  -Dakka.remote.netty.tcp.bind-hostname="$(eval "echo $AKKA_REMOTING_BIND_HOST")" \
  -Dakka.remote.netty.tcp.port="$(eval "echo $AKKA_REMOTING_PORT")"  \
  -Dakka.remote.netty.tcp.bind-port="$(eval "echo $AKKA_REMOTING_BIND_PORT")" \
  $(IFS=','; I=0; for NODE in $AKKA_SEED_NODES; do echo "-Dakka.cluster.seed-nodes.$I=akka.tcp://chirpservice@$NODE"; I=$(expr $I + 1); done)
        env:
          - name: AUTHN_SERVICE_DEBUG
            value: "-d"
          - name: BIKERIDE_SERVICE_DOMAIN
            value: "default.svc.cluster.local"
          - name: BIKERIDE_CASSANDRA_SERVICE
            value: "_casnative._tcp.cassandra.default.svc.cluster.local"
          - name: APPLICATION_SECRET
            value: "changeme!"
          - name: CASSANDRA_SERVICE_NAME
            value: "_casnative._tcp.cassandra.default.svc.cluster.local"
          - name: AUTHN_SERVICE_BIND_PORT
            value: "9000"
          - name: AUTHN_SERVICE_BIND_IP
            value: "0.0.0.0"
          - name: AKKA_REMOTING_PORT
            value: "2551"
          - name: AKKA_REMOTING_BIND_PORT
            value: "2551"
          - name: AKKA_REMOTING_HOST
            value: "$HOSTNAME.bikeride-authentication-service.default.svc.cluster.local"
          - name: AKKA_REMOTING_BIND_HOST
            value: "$HOSTNAME.bikeride-authentication-service.default.svc.cluster.local"
          - name: AKKA_SEED_NODES
            value: "bikeride-authentication-ss-0.bikeride-authentication-service.default.svc.cluster.local:2551,bikeride-authentication-ss-1.bikeride-authentication-service.default.svc.cluster.local:2551,bikeride-authentication-ss-2.bikeride-authentication-service.default.svc.cluster.local:2551"
fernandohackbart commented 7 years ago
fernandohackbart commented 7 years ago

Done and working...