Fine Tunning
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
#!/usr/bin/env python | |
import argparse | |
import os | |
import re | |
import sys | |
from pathlib import Path | |
# Default directories to exclude to mimic the original tool's behavior | |
DEFAULT_EXCLUDE_DIRS = {'.git', 'node_modules', 'vendor', '__pycache__'} |
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
cd ~ && mkdir tmp && cd tmp && git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting && git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions && git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf && ~/.fzf/install && brew install -y autojump && curl -s https://gist.githubusercontent.com/ehc-io/52a3549eb17dda934925149b9048f566/raw/ac4ab8a96dd65a50506293c200de29533ff1b1bb/zshrc -o $HOME/.zshrc |
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
user nginx; | |
worker_processes auto; | |
error_log /var/log/nginx/error.log info; | |
pid /var/run/nginx.pid; | |
# Load the stream module for TCP proxying | |
load_module modules/ngx_stream_module.so; | |
events { | |
worker_connections 1024; |
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
steps: | |
- name: gcr.io/cloud-builders/docker | |
args: | |
- build | |
- '-t' | |
- 'us-central1-docker.pkg.dev/qspe-403603/qspe-images/nginx-demo:$BUILD_ID' | |
- '-f' | |
- Dockerfile | |
- . | |
- name: gcr.io/cloud-builders/docker |
-
With Workload Identity Federation enabled, GKE pods do NOT using the Compute Engine default service account directly.
-
Instead, GKE pods are using Kubernetes service accounts that are mapped to Google service accounts.
To fix this issue:
- Create a dedicated Google service account for your workloads:
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
# Guide to Updating VPN Tunnel and Routes in GCP | |
### ENV Variable Setup (Region and resource names) | |
```bash | |
REGION="us-west1" | |
SITE_LOCAL_ENDPOINT_IP1="my-gateway-prod-by-vpn-ip" | |
SITE_LOCAL_GATEWAY_NAME="my-gateway-prod-by-vpn" | |
SITE_LOCAL_VPC_NAME="mycompany-sql-remotecloud" | |
SITE_LOCAL_VPN_TUNNEL1_NAME="mycompany-to-remotecloud-tunnel" |
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 | |
# | |
# Folder Comparison Tool (folderdiff.sh) | |
# | |
# DESCRIPTION: | |
# This script compares two folders by analyzing their subfolder structures and sizes, | |
# providing a detailed report of the differences. Differences smaller than 300KB are | |
# considered insignificant and marked as "None". The script reports on total sizes, | |
# folders present in only one location, and size discrepancies between common folders. | |
# |
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
import random | |
import string | |
import time | |
from flask import Flask, render_template_string, request, redirect, url_for, session | |
app = Flask(__name__) | |
app.secret_key = "your_secret_key_here" # required for session management | |
# --- Helper Functions --- |
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
#!/usr/bin/env python3.11 | |
import sys | |
import time | |
import re | |
import os | |
import json | |
import argparse | |
import io | |
from youtube_transcript_api import YouTubeTranscriptApi | |
from youtube_transcript_api.formatters import TextFormatter |
NewerOlder