File tree 3 files changed +8
-9
lines changed
3 files changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,6 @@ build-docker: build-bin ## Build docker image
36
36
ensure-prometheus : .cache/prometheus # # Ensures that Prometheus is installed in the project dir. Downloads it if necessary.
37
37
38
38
.PHONY : test
39
- test : export ACR_DB_URL = postgres://user:password@localhost:55432/db?sslmode=disable
40
39
test : ensure-prometheus
41
40
go test ./... -tags integration -coverprofile cover.out -covermode atomic
42
41
72
71
# current date in UTC in ISO 8601 format (RFC 3339) with Z as timezone that works on both linux and macos
73
72
.PHONY : current-date
74
73
current-date :
75
- date -u +" %Y-%m-%dT%H:%M:%SZ"
74
+ date -u +" %Y-%m-%dT%H:%M:%SZ"
Original file line number Diff line number Diff line change @@ -23,12 +23,12 @@ oc login --server=https://api.cloudscale-lpg-2.appuio.cloud:6443
23
23
kubectl --as cluster-admin -nvshn-appuio-mimir service/vshn-appuio-mimir-query-frontend 8080
24
24
25
25
# Set environment
26
- export ACR_PROM_URL =" http://localhost:8080/prometheus"
27
- export ACR_ORG_ID =" appuio-managed-openshift-billing" # mimir organization in which data is stored
28
- export ACR_ODOO_URL =https://test.central.vshn.ch/api/v2/product_usage_report_POST
29
- export ACR_ODOO_OAUTH_TOKEN_URL =" https://test.central.vshn.ch/api/v2/authentication/oauth2/token"
30
- export ACR_ODOO_OAUTH_CLIENT_ID =" your_client_id" # see https://docs.central.vshn.ch/rest-api.html#_authentication_and_authorization
31
- export ACR_ODOO_OAUTH_CLIENT_SECRET =" your_client_secret"
26
+ export AR_PROM_URL =" http://localhost:8080/prometheus"
27
+ export AR_ORG_ID =" appuio-managed-openshift-billing" # mimir organization in which data is stored
28
+ export AR_ODOO_URL =https://test.central.vshn.ch/api/v2/product_usage_report_POST
29
+ export AR_ODOO_OAUTH_TOKEN_URL =" https://test.central.vshn.ch/api/v2/authentication/oauth2/token"
30
+ export AR_ODOO_OAUTH_CLIENT_ID =" your_client_id" # see https://docs.central.vshn.ch/rest-api.html#_authentication_and_authorization
31
+ export AR_ODOO_OAUTH_CLIENT_SECRET =" your_client_secret"
32
32
33
33
# Run a query
34
34
go run . report --query ' sum by (label) (metric)' --begin " 2023-07-08T13:00:00Z" --product-id " your-odoo-product-id" --instance-jsonnet ' local labels = std.extVar("labels"); "instance-%(label)s" % labels' --unit-id " your_odoo_unit_id" --timerange 1h --item-description-jsonnet ' "This is a description."' --item-group-description-jsonnet ' local labels = std.extVar("labels"); "Instance %(label)s" % labels'
Original file line number Diff line number Diff line change 24
24
appLongName = "Reporting for APPUiO Cloud"
25
25
26
26
// envPrefix is the global prefix to use for the keys in environment variables
27
- envPrefix = "ACR "
27
+ envPrefix = "AR "
28
28
)
29
29
30
30
func main () {
You can’t perform that action at this time.
0 commit comments