make reporting-operator-docker-build
docker tag quay.io/openshift/origin-metering-reporting-operator:4.6 default-route-openshift-image-registry.apps-crc.testing/$METERING_NAMESPACE/reporting-opr:debug
oc new-project $METERING_NAMESPACE
docker login -u kubeadmin -p $(oc whoami -t) default-route-openshift-image-registry.apps-crc.testing
docker push default-route-openshift-image-registry.apps-crc.testing/$METERING_NAMESPACE/reporting-opr:debug
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```bash | |
ffmpeg -i ~/Desktop/Screen\ Recording\ 2020-07-14\ at\ 13.16.50.mov -vcodec libx265 -crf 30 ~/Documents/k9s_so_cool.mp4 | |
ffmpeg -i /Users/btofel/Documents/k9s_so_cool.mp4 -c:v copy -c:a copy -tag:v hvc1 /Users/btofel/Documents/k9s_so_cool_mac.mp4 | |
``` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Identify minimal setup for using Metering completely with CRC | |
crc version | |
crc version: 1.11.0+883ca49 | |
OpenShift version: 4.4.5 (embedded in binary) | |
No-fuss CR file that works with CRC for installing Metering | |
cat $METERING_CR_FILE |
Related to this PR: kube-reporting/metering-operator#1213
We don't need to worry about:
which inotify-tools ansible openssl
They're already available from the Anisble base image.
Notes about installing problem packages
python-netaddr, python2-openshift, python2-cryptography
:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: metering.openshift.io/v1 | |
kind: ReportQuery | |
metadata: | |
name: "namespace-persistentvolumeclaim-usage" | |
labels: | |
operator-metering: "true" | |
spec: | |
columns: | |
- name: period_start | |
type: timestamp |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Started with this: | |
[operator-metering] (master)$ pwd | |
/Users/btofel/workspace/operator-metering | |
[operator-metering] (master)$ echo $GOPATH | |
/tmp | |
[operator-metering] (master)$ go mod init github.com/operator-framework/operator-metering | |
go: creating new go.mod: module github.com/operator-framework/operator-metering | |
go: copying requirements from Gopkg.lock | |
go: parsing /Users/btofel/workspace/operator-metering/Gopkg.lock: /Users/btofel/workspace/operator-metering/Gopkg.lock: empty [[projects]] stanza (github.com/operator-framework/operator-lifecycle-manager) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# usage cmd_name <search_term> [<number of chars before & after for context>] | |
# NOTE: wired to metering-operator specifically | |
search_term=$1 | |
context_amt=${2:-50} | |
echo "search term: $search_term" | |
echo "context of chars before & after: $context_amt" | |
docker exec -i metering-operator bash -c 'tail -n +1 -f /tmp/ansible-operator/runner/metering.openshift.io/v1/MeteringConfig/*/*/artifacts/*/stdout' | grep --line-buffered --only-matching --extended-regexp ".{0,${context_amt}}${search_term}.{0,${context_amt}}"|grep --line-buffered --color --extended-regexp "${search_term}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 2 years ago Johan Andrén posted a conversion from Scala of an example of hooking a Websocket to a Stream to an Actor | |
// I had to tweak it a bit to get it to work with more modern version of akka-http | |
// Maven deps for this are: | |
// <!-- http://akka.io/docs/#akka-http --> | |
// <dependency> | |
// <groupId>com.typesafe.akka</groupId> | |
// <artifactId>akka-http-core_2.11</artifactId> | |
// <version>10.0.6</version> | |
// </dependency> |
NewerOlder