This file contains 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
all: cert keycloak | |
cert: | |
mkdir certs | |
openssl req -x509 -newkey rsa:2048 -keyout certs/ca-key.pem \ | |
-out certs/ca.pem -days 3650 -nodes -subj "/CN=auth.alicek106.com" | |
openssl req -newkey rsa:2048 -days 3600 -nodes -keyout certs/server-key.pem -out certs/server-req.pem \ | |
-subj "/CN=mysql" | |
openssl x509 -req -in certs/server-req.pem -days 3600 -CA certs/ca.pem -CAkey certs/ca-key.pem \ | |
-set_serial 01 -out certs/server-cert.pem |
This file contains 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
function tf_prompt_info() { | |
# dont show 'default' workspace in home dir | |
[[ "$PWD" == ~ ]] && return | |
# check if in terraform dir | |
if [ -d .terraform ]; then | |
# Most of scripts uses 'terraform workspace show' but it's too slow in some cases. | |
# We can just bring out the environment file to bash | |
if [ -f .terraform/environment ]; then | |
workspace=$(cat .terraform/environment 2> /dev/null) || return | |
echo "[${workspace}]" |
This file contains 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
const React = require("react") | |
const Keycloak = require("keycloak-js") | |
const { KeycloakProvider } = require("@react-keycloak/web") | |
const keycloak = new Keycloak({ | |
realm: 'alicek106', | |
url: 'https://auth.alicek106.com/auth', | |
clientId: 'react-frontend', | |
}) |
This file contains 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
node: | |
id: node0 # 고유한 envoy node의 ID | |
cluster: cluster.local | |
admin: # Envoy는 자체적으로 Admin 페이지를 제공한다. | |
access_log_path: /tmp/admin_access.log | |
address: | |
socket_address: { address: 0.0.0.0, port_value: 9900 } # 9900 포트로 Admin 접근 가능 | |
static_resources: |
This file contains 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
import logging | |
from flask import Flask, request | |
class ServicesDAO(object): | |
def __init__(self): | |
self.services = {} | |
def get(self, service_name): |
This file contains 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: monitoring.coreos.com/v1 | |
kind: Alertmanager | |
metadata: | |
labels: | |
owner: alicek106 | |
name: alice-alertmanager | |
namespace: default | |
spec: | |
configMaps: | |
- alert-notification-tmpl |
This file contains 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: monitoring.coreos.com/v1 | |
kind: PrometheusRule | |
metadata: | |
labels: | |
owner: alicek106 | |
role: alert-rules | |
name: example-app-latency | |
namespace: default | |
spec: | |
groups: |
This file contains 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: monitoring.coreos.com/v1 | |
kind: ServiceMonitor | |
metadata: | |
name: istio-mesh-monitor | |
namespace: default | |
labels: | |
app: monitoring | |
monitoring: istio-mesh | |
spec: | |
selector: |
This file contains 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: monitoring.coreos.com/v1 | |
kind: ServiceMonitor | |
metadata: | |
name: istio-component-monitor | |
namespace: default | |
labels: | |
app: monitoring | |
monitoring: istio-components | |
spec: | |
jobLabel: istio |
This file contains 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: apps/v1 | |
kind: Deployment | |
metadata: | |
name: ingress-annotation-test | |
namespace: example-app | |
labels: | |
app: ingress-annotation-test | |
spec: | |
replicas: 3 | |
selector: |
NewerOlder