Skip to content

Instantly share code, notes, and snippets.

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

zengqingfu1442 zengqingfu1442

🏠
Working from home
View GitHub Profile
@Bill-tran
Bill-tran / how-to-install-openssl-1.1.1-on-centos-7.md
Created September 7, 2021 09:22
How to install openssl 1.1.1 on CentOS 7

How To Install OpenSSL 1.1.1 on CentOS 7

This tutorial goes through how to install openssl 1.1.1 on CentOS 7, since the yum repo only installs up to openssl 1.0.

Requirements

Upgrade the system

yum -y update
@kralicky
kralicky / harvester-gpu.md
Last active March 1, 2025 15:40
Harvester GPU Provisioning

Harvester GPU Provisioning

  1. Install Harvester, then SSH into the server.

  2. Edit /boot/grub/grub.cfg as follows:

 set default=0
 set timeout=10
 
version: '3'
services:
postgres:
container_name: container-postgresdb
image: postgres
hostname: postgres
ports:
- "6543:5432"
environment:
POSTGRES_USER: postgres
@yaocw2020
yaocw2020 / Harvester-SNAT-problem.md
Last active April 28, 2024 15:24
harvester design

Harvester SNAT Problem

Problem Description

Harvester leverages the Kubernetes service to provide the load balancer for the service in the Harvester virtual machines. The backend servers of the load balancer are the <VM IP>:<service port>.

cw-harv:/home/rancher # kubectl get svc
NAME                        TYPE           CLUSTER-IP      EXTERNAL-IP    PORT(S)        AGE
default-nginx-lb-db9bdca5 LoadBalancer 10.43.113.238 80:32586/TCP 4h32m
#!/bin/sh
DateStamp=$(date +%d%m%y)
BackupDirectory="/data/configdb/backup"
mkdir -p $BackupDirectory
sslCAFile="/data/configdb/mongodb-ssl-cert.pem"
DATABASE='database'
USERNAME='user'
@aafaque33
aafaque33 / .gitlab-ci.yml
Created June 21, 2019 21:25
Gitlab anybadge to generate badge
stages:
- build
create_badge_svg:
stage: build
image: python:3.6.6
tags:
- docker
script:
- echo "Python other dependencies installation"
@y0ngb1n
y0ngb1n / docker-registry-mirrors.md
Last active December 9, 2025 15:39
国内的 Docker Hub 镜像加速器,由国内教育机构与各大云服务商提供的镜像加速服务 | Dockerized 实践 https://github.com/y0ngb1n/dockerized
@DahlitzFlorian
DahlitzFlorian / Dockerfile
Last active March 31, 2022 10:56
Run Python application as non-root in Docker - requirements.txt
FROM python:3.7.2-alpine
RUN pip install --upgrade pip
RUN adduser -D worker
USER worker
WORKDIR /home/worker
COPY --chown=worker:worker requirements.txt requirements.txt
RUN pip install --user -r requirements.txt
@wxingheng
wxingheng / mac os下vscode快捷键
Created October 7, 2018 15:03
mac os下vscode快捷键
[mac os下vscode快捷键](https://www.cnblogs.com/informatics/p/8315339.html)
全局
Command + Shift + P / F1 显示命令面板
Command + P 快速打开
Command + Shift + N 打开新窗口
Command + W 关闭窗口
基本
Command + X 剪切(未选中文本的情况下,剪切光标所在行)
Command + C 复制(未选中文本的情况下,复制光标所在行)
@holmberd
holmberd / linux-kill-pts.md
Last active August 14, 2025 09:24
Kill tty/pts sessions in Linux

Kill user tty/pts sessions in Linux

Commands

  • w: show who is logged on and what they are doing
  • who: show who is logged on
  • tty: show current users pseudo terminal
  • ps -ft pts/1: get process id for the pseudo terminal
  • pkill: signal process based on name and other attributes