Jamie Hannaford | 249bb62 | 2014-11-07 12:11:26 +0100 | [diff] [blame] | 1 | package ssl |
Jamie Hannaford | 276a032 | 2014-11-06 14:26:12 +0100 | [diff] [blame] | 2 | |
| 3 | import ( |
| 4 | "strconv" |
| 5 | |
| 6 | "github.com/rackspace/gophercloud" |
| 7 | ) |
| 8 | |
| 9 | const ( |
Jamie Hannaford | 249bb62 | 2014-11-07 12:11:26 +0100 | [diff] [blame] | 10 | path = "loadbalancers" |
| 11 | sslPath = "ssltermination" |
| 12 | certPath = "certificatemappings" |
Jamie Hannaford | 276a032 | 2014-11-06 14:26:12 +0100 | [diff] [blame] | 13 | ) |
| 14 | |
| 15 | func rootURL(c *gophercloud.ServiceClient, id int) string { |
| 16 | return c.ServiceURL(path, strconv.Itoa(id), sslPath) |
| 17 | } |
Jamie Hannaford | 249bb62 | 2014-11-07 12:11:26 +0100 | [diff] [blame] | 18 | |
| 19 | func certURL(c *gophercloud.ServiceClient, id int) string { |
| 20 | return c.ServiceURL(path, strconv.Itoa(id), sslPath, certPath) |
| 21 | } |
Jamie Hannaford | cba541e | 2014-11-07 13:36:54 +0100 | [diff] [blame] | 22 | |
| 23 | func certResourceURL(c *gophercloud.ServiceClient, id, certID int) string { |
| 24 | return c.ServiceURL(path, strconv.Itoa(id), sslPath, certPath, strconv.Itoa(certID)) |
| 25 | } |