Spinnaker

Spinnaker is an open-source, multi-cloud continuous delivery platform used for releasing software changes with high velocity and confidence. It is designed to work seamlessly with cloud-native technologies and supports multi-cloud environments.

Spinnaker can be integrated with Delivery Shield using any of two methods given below:

  • Integration using Webhook

  • Integration through Config changes in the Spinnaker Gitops

Prerequisites:

  • Delivery Shield

  • Spinnaker

Integration using Webhook

Delivery Shield can be integrated with Spinnaker using the webhook configuration in Spinnaker. Follow the steps given below to complete this integration process:

  1. Add the below configuration in the default/profiles/ echo-local.yml file of the Spinnaker gitops repo.

rest
  enabled: true
  endpoints:
    -
      wrap: true
      url: https://aug-dev.oes.opsmx.org/ssdservice/v1/spinnakerevents
      #headers: {"organization":"opsmx"} (Name that is entered in the API setup)
      headers: {"token": "eyJhbGciOiJSUzI1NiIsImtpZCI6IjliOTNjOWRiLWRhYjAtNGYwNC05OGFjLTU3YTI0NmYwMjk2ZiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJPcHNNeCIsImF1ZCI6WyJzc2Qub3BzbXguaW8iXSwiZXhwIjoxNzU5NzMwNDI0LCJuYmYiOjE3MjU2MDI0MjQsImp0aSI6ImFiY2QxMjM0Iiwic3NkLm9wc214LmlvIjp7InR5cGUiOiJpbnRlZ3JhdGlvbi92MSIsIm9yZ0lEIjoiMjhkMWVjM2QtZWE3Ni00YWVhLTllZGEtZjQzODczMTUzOTMyIiwidGVhbUlEIjoiNzQ5NjM3MjMtYjFjYi00YzY4LThhYTYtZDhlZTMwZDg0YWZhIn19.TIuZHyOIhzowF6MQYc3ZlSga4vASabeD4UtgAr8lUkTvPxqjBeN02a9Y9tERRZH5rqCRCRjUJoESm-042OJp0zhE_bbaPY866NWq3s9vb_q8vaJ54kDd11_gj-KvLwQ5n8Pe2eiW4Giv6bpCe_iQJQgFigboyFk0Y3xnDfCxPn5WdXLPLq00pIsg7a8CDZN-M2ZR76uBBUgKko-B9SicZnhYqKUP1noVjJsb42Z_eMSEoYm3nScRjJqTe8oEq2Sw31k7ZyhTesKND8PzfMopt26CM_myVr0D52Ep-dN8eFzQvNwNXFf0-xKSa1Q-E5stlrWaylsklnoKm1PKepny7A"}
      eventName: preview-saas-ssd
      flatten: true
  • url: Replace the SSD-UI.URL.COMPANY.COM value with your SSD UI ingress value.

  • eventName: Default value for this field is preview-saas-ssd. This value should be same as the queue and bindingKey value of the spinnakerConfig.yml in the supplychain-preprocessor secret in SSD. If you change this value in the supplychain-preprocessor secret, then you need to provide the same value here also.

  1. Now restart the halyard pod of the spinnaker using the command given below:

kubectl delete po <halyard pod name> -n <namespace name>

Integration through Config changes in Spinnaker Gitops:

Few custom changes in the Spinnaker gitops repo needs to be done to push the echo events to Delivery Shield. Follow the instructions given below to update the changes in gitops repo.

  1. Update the images mentioned below in the bom file of the gitops repo. In case if you are not using the bom file then update the images in the default/service-settings/echo-*.yml and deck.yml files.

echo:
    Image: quay.io/opsmxpublic/ubi8-oes-echo:b5dad694-OP-21052-v4.0-Testing

  deck:
    image: quay.io/opsmxpublic/ubi8-oes-deck:82451241c-13
  1. Add the below configuration at the root level in the default/profiles/echo-local.yml file.

message-broker:
  endpoint:
      name: rabbitmq
  username: rabbitmq              
  password: Abcd123       
  host: rabbitmq-service
  port: 5672
ssd:
  name: preview-saas-ssd
  enable: true
  • message-broker.endpoint.name: Provide a name for the RabbitMQ connection. Default value is rabbitmq.

  • message-broker.username: Provide the SSD RabbitMQ username.

  • message-broker.password: Provide the SSD RabbitMQ password.

  • message-broker.host: Provide the SSD RabbitMQ host details. If the SSD is hosted in a different cluster then give external IP address or DNS value of that service.

  • message-broker.port: Provide the rabbitmq-service port number. Default value is 5672.

  • ssd.name: Default value is preview-saas-ssd. This value should be same as queue and bindingKey value of spinnakerConfig.yml in supplychain-preprocessor secret in SSD. If you change this value in supplychain-preprocessor secret, then you need to provide the same value here also.

  1. Now restart the halyard pod of the spinnaker using the command given below:

kubectl delete po <halyard pod name> -n <namespace name>

Adding container labels in Deployment files

Once Spinnaker is integrated, add the below mentioned container labels in the deployments files used by the pipelines of spinnaker.

ssd.admissionreview.accountname: ${parameters.account}
ssd.admissionreview.appname: ${execution.application}

TroubleShooting:

If you face any issues while integrating Spinnaker to Delivery Shield, feel free to contact OpsMx support team.

Last updated