For the next steps, you will need access to an OpenShift cluster (4.3 or newer).
-
In OpenShift, create a namespace called
openshift-metering
if one does not exist, and label the namespace withopenshift.io/cluster-monitoring=true
. -
Install the Metering Operator in the
openshift-metering
namespace, using the OpenShift web console (search for Metering in OperatorHub). -
Create a key/value secret in the
openshift-metering
namespace calledmetering-aws
where the keys areaws-access-key-id
andaws-secret-access-key
with your associated aws secret values. -
Create a Metering Configuration that points to your bucket/path/ and region, and references the aws secret that you created above. It should look similar to the following:
apiVersion: metering.openshift.io/v1
kind: MeteringConfig
metadata:
name: operator-metering
namespace: openshift-metering
spec:
storage:
hive:
s3:
bucket: your-bucketname/path/
createBucket: false
region: us-east-1
secretName: metering-aws
type: s3
type: hive
To check that Metering has been configured correctly, you can view & ensure that all of the pods are running & ready.