blob: aa814b3583457ca3409e723d4060d29b65398180 [file] [log] [blame]
Jamie Hannaford249bb622014-11-07 12:11:26 +01001package ssl
Jamie Hannaford276a0322014-11-06 14:26:12 +01002
3import (
4 "strconv"
5
6 "github.com/rackspace/gophercloud"
7)
8
9const (
Jamie Hannaford249bb622014-11-07 12:11:26 +010010 path = "loadbalancers"
11 sslPath = "ssltermination"
12 certPath = "certificatemappings"
Jamie Hannaford276a0322014-11-06 14:26:12 +010013)
14
15func rootURL(c *gophercloud.ServiceClient, id int) string {
16 return c.ServiceURL(path, strconv.Itoa(id), sslPath)
17}
Jamie Hannaford249bb622014-11-07 12:11:26 +010018
19func certURL(c *gophercloud.ServiceClient, id int) string {
20 return c.ServiceURL(path, strconv.Itoa(id), sslPath, certPath)
21}
Jamie Hannafordcba541e2014-11-07 13:36:54 +010022
23func certResourceURL(c *gophercloud.ServiceClient, id, certID int) string {
24 return c.ServiceURL(path, strconv.Itoa(id), sslPath, certPath, strconv.Itoa(certID))
25}