feat: Update san cert config endpoint

- REQUEST

  POST
http://127.0.0.1:8888/v1.0/admin/ssl_certificate/san_cert_config/{{san_cert_name}}

  { 'spsId': 4324 }

- RESPONSE

  200

  {
  "ipVersion": "ipv4",
  "slot-deployment.class": "esslType",
  "createType": "modSan",
  "jobId": "5123",
  "cnameHostname": "secure2.test-san.com",
  "spsId": "4324",
  "issuer": "symantec"
   }

Implements: blueprint akamai-san-cert-config
Change-Id: I69f17a0064f20b6068365db3eaae2f21bf20d193
This commit is contained in:
Tony Tan
2016-02-12 16:22:31 -05:00
parent 3edbb363a1
commit 73a3d28132
10 changed files with 177 additions and 11 deletions

View File

@@ -267,9 +267,13 @@ class CassandraSanInfoStorage(base.BaseAkamaiSanInfoStorage):
def get_cert_config(self, san_cert_name):
res = self.get_cert_info(san_cert_name)
res['spsId'] = self.get_cert_last_spsid(san_cert_name)
res['spsId'] = str(self.get_cert_last_spsid(san_cert_name))
return res
def update_cert_config(self, san_cert_name, new_spsId):
self.save_cert_last_spsid(san_cert_name, new_spsId)
return self.get_cert_config(san_cert_name)
def save_cert_last_spsid(self, san_cert_name, sps_id_value):
san_info = self._get_akamai_san_certs_info()
the_san_cert_info = san_info.get(