Skip to content

Instantly share code, notes, and snippets.

View hoangdh's full-sized avatar
🏠
Working from home

Dao Huy Hoang hoangdh

🏠
Working from home
View GitHub Profile

Tải pyinnodb

apt update && apt install wget -y; 
wget https://github.com/WinChua/pyinnodb/releases/latest/download/pyinnodb.sh -P /opt/;
chmod a+x /opt/pyinnodb.sh

Chuyển đổi idb sang SQL

Workflow tổng quan

1. Thu thập/Tạo nội dung

  • Nguồn nội dung
    • Tự tạo: Bài viết, hình ảnh, video được chuẩn bị trước.
    • Lấy từ RSS feeds/Websites: Tự động thu thập nội dung từ các nguồn tin liên quan đến lĩnh vực của bạn.
    • AI Generated Content: Sử dụng AI để tạo nội dung mới (ví dụ: tiêu đề, mô tả, bài viết ngắn, hình ảnh, thumbnail).
  • Lưu trữ: Lưu trữ nội dung trong một hệ thống quản lý nội dung (CMS) hoặc bảng tính/cơ sở dữ liệu.

Prompt Perplexity hỗ trợ SEO

Tác giả: Bui Viet Anh @NghienAI

Đây là một prompt rất mạnh dành cho Perplexity để hỗ trợ SEO. Prompt này có các vai trò chuyên biệt và đạt hiệu quả cao nhất.

Danh sách các vai trò :

  • CONTENT STRATEGIST (Chiến lược nội dung)
  • TECHNICAL SEO EXPERT (Chuyên gia SEO kỹ thuật)
  • KEYWORD RESEARCHER (Nghiên cứu từ khóa)
@hoangdh
hoangdh / ssh-agent.md
Created February 26, 2025 09:09
Bypass pass-phase when run ansible-playbook

Run SSH-Agent

eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_rsa

Run playbook

@hoangdh
hoangdh / bingart-api.md
Last active March 17, 2025 09:00
Tạo hình ảnh bằng Bing Art thông qua API.

Tạo hình ảnh bằng Bing Art AI của Microsoft thông qua API

Script API

from flask import Flask, request, jsonify, render_template
from bingart import BingArt

# Replace your cookie
myCookie = ''
@hoangdh
hoangdh / nvidia-driver-install.md
Last active February 27, 2025 10:43
Hướng dẫn cài đặt Driver GPU NVIDIA trên Ubuntu 22.04

Hướng dẫn cài đặt NVIDIA Driver trên Ubuntu 22.04

Cài đặt repository của NVIDIA

wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.1-1_all.deb
dpkg -i cuda-keyring_1.1-1_all.deb
@hoangdh
hoangdh / n8n.md
Last active March 23, 2025 04:04
n8n self-host with ngrok

n8n with Docker and ngrok

docker volume create n8n-volume

docker run -d --name n8n \
-e N8N_SECURE_COOKIE=false \
@hoangdh
hoangdh / install-openssh-9.3p2.md
Created May 17, 2024 07:02
Compile OpenSSH 9.3p2 from Source code
@hoangdh
hoangdh / jupyter-notes.md
Last active November 26, 2024 03:46
Một vài bước cài đặt Jupyterhub

Cài đặt Jupyter qua conda

conda install -c conda-forge jupyterhub  # installs jupyterhub and proxy
conda install jupyterlab notebook  # needed if running the notebook servers in the same environment

File cấu hình

Filename: jupyterhub_config.py

@hoangdh
hoangdh / migrate-mongodb.md
Last active November 26, 2024 03:44
Migrate data MongoDB to another cluster without dumping to local disk

Migrate data MongoDB to another cluster

  • Source cluster: 10.10.10.10
  • Destination cluster: 10.10.20.10
mongodump --host 10.10.10.10 --port 27017 --archive --numParallelCollections=10 | \
mongorestore --host 10.10.20.10 --port 27017 --archive --numParallelCollections=10 --drop