Keywords: Java, JDK (Java Development Kit), MacOS, Homebrew, Specific Version
This how-to guide covers how to install different versions of the JDK on MacOS with Homebrew.
| #!/usr/bin/env python | |
| import json | |
| from jinja2 import Template | |
| # git clone https://github.com/pingcap/tidb-docker-compose | |
| # cd tidb-docker-compose | |
| # git clone https://github.com/tennix/grafonnet-lib -b table | |
| # python dashboard-to-jsonnet.py > pd.jsonnet | |
| # jsonnet -J grafonnet-lib pd.jsonnet > config/dashboards/generated-pd.json | |
| with open('config/dashboards/pd.json', 'r') as f: | |
| data = json.load(f) |
Keywords: Java, JDK (Java Development Kit), MacOS, Homebrew, Specific Version
This how-to guide covers how to install different versions of the JDK on MacOS with Homebrew.
| #/bin/bash | |
| # | |
| # Extract the app version number from an APK/IPA file (on Linux) | |
| # | |
| # Required tools: aapt, plistutil, xmllint | |
| # | |
| # Usage: | |
| # ------ | |
| # getAppVersion.sh android pathToApk | |
| # getAppVersion.sh ios pathToIpa AppName.app |
adb shell pm list packages
Look through the list of package names and try to find a match between the app in question and the package name. This is usually easy, but note that the package name can be completely unrelated to the app name. If you can't recognize the app from the list of package names, try finding the app in Google Play using a browser. The URL for an app in Google Play contains the package name.
(Assuming a Debian 8-like system)
Install prometheus-node-exporter
$ sudo apt update && sudo apt install prometheus-node-exporterConfigure prometheus-node-exporter to expose metrics only to localhost, not on to all networks. Modify file /etc/default/prometheus-node-exporter:
# Set the command-line arguments to pass to the server.| """ | |
| Queries the slowlog database table maintained by Amazon RDS and outputs it in | |
| the normal MySQL slow log text format. Modified version of the script by | |
| memonic (Thanks!) at https://gist.github.com/1481025 | |
| Things to change in this script for your own setup: | |
| <root_user> to your mysql root user (e.g. "root") | |
| <root_pass> to your mysql root password (e.g. "hunter2") | |
| <host_domain> to your mysql root password (e.g. "prod-01.w3rfs2.us-east-1.rds.amazonaws.com") |