Skip to content

Instantly share code, notes, and snippets.

View pplmx's full-sized avatar
💭
Thinking

Mystic pplmx

💭
Thinking
View GitHub Profile
@pplmx
pplmx / init.gradle
Last active December 5, 2021 06:30
Gradle Global Repo in Aliyun
allprojects {
buildscript {
repositories {
maven { url 'https://maven.aliyun.com/repository/public' }
maven { url 'https://maven.aliyun.com/repository/google' }
maven { url 'https://maven.aliyun.com/repository/spring' }
maven { url 'https://maven.aliyun.com/repository/spring-plugin' }
maven { url 'https://maven.aliyun.com/repository/gradle-plugin' }
maven { url 'https://maven.aliyun.com/repository/grails-core' }
maven { url 'https://maven.aliyun.com/repository/apache-snapshots' }
@pplmx
pplmx / Dockerfile
Created December 21, 2021 06:08
SonarQube Scanner NodeJS project
FROM sonarqube:community
USER root
# --no-cache: download package index on-the-fly, no need to cleanup afterwards
# --virtual: bundle packages, remove whole bundle at once, when done
# Using --no-cache avoids having to use rm -rf /var/cache/apk/*;
# Using --virtual allows you to remove multiple packages required during build only at once
RUN apk --update --no-cache --virtual build-dependencies add \
nodejs \
@pplmx
pplmx / init.sh
Last active August 27, 2022 13:57
ubuntu init
#!/usr/bin/env bash
# change the apt sources to aliyun
cat << EOF > /etc/apt/sources.list
deb https://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse
deb https://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse
deb https://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse
deb https://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
EOF
@pplmx
pplmx / .gitconfig
Last active September 15, 2022 01:39
[init]
defaultBranch = main
[pull]
rebase = true
[fetch]
prune = true
[alias]
ld = log --stat --graph --oneline
lf = log --graph --pretty=format:'%C(red)%h%Creset %C(cyan)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=short --all
lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
@pplmx
pplmx / instruction.md
Created September 22, 2022 11:07
ssh without password

SSH without PASSWORD

~/.ssh/config

assume you have this remote ssh server config on your ssh config

Host aurora
	HostName 192.168.10.66
	User aurora
@pplmx
pplmx / config
Last active October 27, 2022 11:23
~/.ssh/config Speeding up SSH Connection Creation
Host *
TCPKeepAlive yes
ServerAliveInterval 60
ServerAliveCountMax 30
Compression yes
ControlMaster auto
ControlPath /tmp/%r@%h:%p
ControlPersist 8h
# StrictHostKeyChecking no
PreferredAuthentications publickey,password
@pplmx
pplmx / config.json
Created October 28, 2022 08:35
Docker Registry Mirrors
"registry-mirrors":[
"https://hub-mirror.c.163.com/",
"https://docker.mirrors.ustc.edu.cn/",
"https://reg-mirror.qiniu.com/",
"https://registry.docker-cn.com",
"https://mirror.ccs.tencentyun.com"
]
[base]
name=CentOS-vault-6.10 - Base - mirrors.aliyun.com
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos-vault/6.10/os/$basearch/
http://mirrors.aliyuncs.com/centos-vault/6.10/os/$basearch/
http://mirrors.cloud.aliyuncs.com/centos-vault/6.10/os/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos-vault/RPM-GPG-KEY-CentOS-6
#released updates
@pplmx
pplmx / docker-compose.yml
Last active March 1, 2023 10:21
docker compose healthcheck
version: Compose specification
services:
proxy:
image: nginx
container_name: nginx
restart: always
ports:
- "8080:80"
healthcheck:
# 1. if curl or wget is not available, maybe try this
@pplmx
pplmx / init.toml
Last active March 3, 2023 06:39
SpaceVim init.toml
#=============================================================================
# dark_powered.toml --- dark powered configuration example for SpaceVim
# Copyright (c) 2016-2022 Wang Shidong & Contributors
# Author: Wang Shidong < wsdjeg@outlook.com >
# URL: https://spacevim.org
# License: GPLv3
#=============================================================================
# All SpaceVim option below [option] section
[options]