Skip to content

Instantly share code, notes, and snippets.

View 1eedaegon's full-sized avatar
Need more mocha =]

Gon ⌬ 1eedaegon

Need more mocha =]
  • Anywhere you want
  • 18:49 (UTC +09:00)
View GitHub Profile
@1eedaegon
1eedaegon / how-to-solve-nvidia-driver-error-2.md
Last active June 18, 2025 00:38
Problem: NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.

Situation

NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.

Even after properly installing the NVIDIA driver, the following error occurs: NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.

1. On Mainboard

Set the following three items in the BIOS.

If these settings are not available in the BIOS, download and update it via USB.

@1eedaegon
1eedaegon / how-to-install-podman-with-docker-compose.sh
Last active May 22, 2025 07:46
How to install podman cli with docker compose
#!/bin/bash
# 1. Install podman using *homebrew*
brew install podman
# 2. Docker-compose
brew install docker-compose
# 3. Create a symbolic link from podman to docker
ln -s $(which podman) /usr/bin/docker
@1eedaegon
1eedaegon / install.sh
Created April 25, 2025 09:19 — forked from DPS0340/install.sh
install openssl 1.1.1 on ubuntu 22.04 arm64
# download binary openssl packages from Impish builds
wget http://ports.ubuntu.com/pool/main/o/openssl/openssl_1.1.1f-1ubuntu2_arm64.deb
wget http://ports.ubuntu.com/pool/main/o/openssl/libssl-dev_1.1.1f-1ubuntu2_arm64.deb
wget http://ports.ubuntu.com/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_arm64.deb
# install downloaded binary packages
sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_arm64.deb
sudo dpkg -i libssl-dev_1.1.1f-1ubuntu2_arm64.deb
sudo dpkg -i openssl_1.1.1f-1ubuntu2_arm64.deb
@1eedaegon
1eedaegon / how-to-setup-airflow.service
Created April 10, 2025 03:13
how to setup airflow using systemd with venv
######### Ariflow Web #########
[Unit]
Description=Airflow Webserver
After=network.target
[Service]
User=1000
Group=1000
WorkingDirectory=/home/ec2-user/workspace/airflow-venv
Environment=AIRFLOW_HOME=/home/ec2-user/workspace/airflow-venv # venv path
@1eedaegon
1eedaegon / how-to-use-pip-on-uv.sh
Last active April 28, 2025 07:24
How to use pip in a Python environment installed with uv
#!/bin/bash
# 0. Install UV
# (Optional)using nix
# nix profile install github:1eedaegon/...s#py
wget -qO- https://astral.sh/uv/install.sh | sh
# 1. Install python
uv venv --python 3.12
@1eedaegon
1eedaegon / login-ecr.sh
Last active April 7, 2025 06:40
How to AWS ECR login using aws cli
#!/bin/sh
REGION=ap-northeast-2
$(aws ecr get-login --no-include-email --region $REGION)
# OR
# aws ecr get-login-password --region $REGION | docker login AWS --password-stdin [NUMBER].dkr.ecr.$REGION.amazonaws.com
@1eedaegon
1eedaegon / solve-using-systemd.md
Created April 26, 2024 05:39
/mnt/c/Users/[]/AppData/Local/Programs/Microsoft VS Code/bin/code: 61: /mnt/c/Users/[]/AppData/Local/Programs/Microsoft VS Code/Code.exe: Exec format error

Problem

When start vscode on WSL2 using "code" command

/mnt/c/Users/[PC NAME]/AppData/Local/Programs/Microsoft VS Code/bin/code: 61: /mnt/c/Users/[PC NAME]/AppData/Local/Programs/Microsoft VS Code/Code.exe: Exec format error

❯ code .
/mnt/c/Users/[]/AppData/Local/Programs/Microsoft VS Code/bin/code: 61: /mnt/c/Users/[]/AppData/Local/Programs/Microsoft VS Code/Code.exe: Exec format error

Solution

@1eedaegon
1eedaegon / solution.md
Last active April 24, 2024 07:55
solution: kubebuilder The CustomResourceDefinition "blah" is invalid: metadata.annotations: Too long: must have at most 262144 bytes

Trouble sample

like this: is invalid: metadata.annotations: Too long: must have at most 262144

make install # kubeduiler generated makefile

/home/lee-ubuntu/workspace/pipeline-operator/bin/kustomize-v5.3.0 build config/crd | kubectl apply -f -
customresourcedefinition.apiextensions.k8s.io/pipelines.pipeline.1eedaegon.github.io unchanged
customresourcedefinition.apiextensions.k8s.io/tasks.pipeline.1eedaegon.github.io unchanged
The CustomResourceDefinition "runs.pipeline.1eedaegon.github.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes
@1eedaegon
1eedaegon / prevent-docker-failed.md
Last active April 26, 2024 05:36
When start failed docker on wsl2 ubuntu

Inspect log

Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? See journal

journalctl -xeu docker

Nov 15 14:42:36 1eegram systemd[1]: Starting Docker Application Container Engine...
░░ Subject: A start job for unit docker.service has begun execution
░░ Defined-By: systemd
@1eedaegon
1eedaegon / get-remote.sh
Last active November 27, 2023 12:46
How to get git remote path without semi colon
# 1.
$(git remote -v | tail -1 | awk -F"@" '{print$2}' | awk -F".git" '{print$1}' | sed 's/:/\//g')
# 2.
$(git remote -v | sed -n '1p' | awk -F '@' '{print $2}' | sed -e 's/\:/\//g' | awk -F '.git' '{print $1}')
# example
❯ go mod init $(git remote -v | tail -1 | awk -F"@" '{print$2}' | awk -F".git" '{print$1}' | sed 's/:/\//g')
go: creating new go.mod: module github.com/1eedaegon/ory-practice