Ver código fonte

Merge branch 'develop' into feat/pricing-summary-endpoint

Mark 3 anos atrás
pai
commit
02f060c9b1
2 arquivos alterados com 17 adições e 9 exclusões
  1. 1 1
      README.md
  2. 16 8
      pkg/cloud/provider.go

+ 1 - 1
README.md

@@ -37,7 +37,7 @@ and contributing changes.
 
 
 ## Community
 ## Community
 
 
-If you need any support or have any questions on contributing to the project, you can reach us on [CNCF Slack](https://slack.cncf.io/) in the [#opencost](https://cloud-native.slack.com/archives/C03D56FPD4G) channel or via email at [opencost@kubecost.com](opencost@kubecost.com).
+If you need any support or have any questions on contributing to the project, you can reach us on [CNCF Slack](https://slack.cncf.io/) in the [#opencost](https://cloud-native.slack.com/archives/C03D56FPD4G) channel, email at [opencost@kubecost.com](opencost@kubecost.com), or attend the [OpenCost Working Group meetings](https://bit.ly/opencost-meeting) from the [Community Calendar](https://bit.ly/opencost-calendar).
 
 
 ## FAQ
 ## FAQ
 
 

+ 16 - 8
pkg/cloud/provider.go

@@ -158,14 +158,22 @@ type OutOfClusterAllocation struct {
 }
 }
 
 
 type CustomPricing struct {
 type CustomPricing struct {
-	Provider                     string `json:"provider"`
-	Description                  string `json:"description"`
-	CPU                          string `json:"CPU"`
-	SpotCPU                      string `json:"spotCPU"`
-	RAM                          string `json:"RAM"`
-	SpotRAM                      string `json:"spotRAM"`
-	GPU                          string `json:"GPU"`
-	SpotGPU                      string `json:"spotGPU"`
+	Provider    string `json:"provider"`
+	Description string `json:"description"`
+	// CPU a string-encoded float describing cost per core-hour of CPU.
+	CPU string `json:"CPU"`
+	// CPU a string-encoded float describing cost per core-hour of CPU for spot
+	// nodes.
+	SpotCPU string `json:"spotCPU"`
+	// RAM a string-encoded float describing cost per GiB-hour of RAM/memory.
+	RAM string `json:"RAM"`
+	// SpotRAM a string-encoded float describing cost per GiB-hour of RAM/memory
+	// for spot nodes.
+	SpotRAM string `json:"spotRAM"`
+	GPU     string `json:"GPU"`
+	SpotGPU string `json:"spotGPU"`
+	// Storage is a string-encoded float describing cost per GB-hour of storage
+	// (e.g. PV, disk) resources.
 	Storage                      string `json:"storage"`
 	Storage                      string `json:"storage"`
 	ZoneNetworkEgress            string `json:"zoneNetworkEgress"`
 	ZoneNetworkEgress            string `json:"zoneNetworkEgress"`
 	RegionNetworkEgress          string `json:"regionNetworkEgress"`
 	RegionNetworkEgress          string `json:"regionNetworkEgress"`