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: v1 | |
kind: Service | |
metadata: | |
name: nsqlookupd-statefulset | |
spec: | |
ports: | |
- port: 4160 | |
name: nsqlookupd-tcp | |
- port: 4161 |
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: v1 | |
kind: ServiceAccount | |
metadata: | |
name: filebeat | |
--- | |
apiVersion: rbac.authorization.k8s.io/v1 | |
kind: ClusterRole | |
metadata: | |
name: filebeat |
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: v1 | |
kind: Secret | |
metadata: | |
name: hello-secret | |
type: Opaque | |
data: | |
SECRET_VALUE: SGVsbG8gU2VjcmV0 | |
# SGVsbG8gU2VjcmV0 is 'Hello Secret' | |
--- |
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: v1 | |
kind: Namespace | |
metadata: | |
name: temp | |
--- | |
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: shell |
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: batch/v1 | |
kind: Job | |
metadata: | |
name: get-weather | |
spec: | |
template: | |
spec: | |
containers: | |
- image: rbudiharso/weather-job |
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: batch/v1beta1 | |
kind: CronJob | |
metadata: | |
name: periodic-weather | |
spec: | |
schedule: "*/1 * * * *" | |
jobTemplate: | |
spec: | |
template: |
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/sh | |
# requirements | |
# - wget | |
# prepare directory | |
mkdir -p ~/.local/bin | |
mkdir -p ~/.config | |
if ! [ -x "$(command -v tmux)" ]; then |
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
# put this function in your .bashrc or .zshrc and call shf for easy host selection | |
# requirements: | |
# - grep | |
# - fzf | |
ssf() { | |
host=$(grep -e "^Host " ~/.ssh/config | awk '{print $2}' | fzf) | |
echo "SSH session started, connecting to" $host | |
ssh $host | |
} |
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/sh | |
OLDREMOTE=aksivisitama | |
NEWREMOTE=usetada | |
sed -i "s/github.com:$OLDREMOTE/github.com:$NEWREMOTE/g" ./.git/config |
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 | |
# create node_exporter.service | |
cat > /etc/systemd/system/node_exporter.service <<END | |
[Unit] | |
Description=node_exporter service | |
After=network.target | |
[Service] | |
ExecStart=/usr/local/bin/node_exporter |
OlderNewer