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
| server { | |
| listen 80; | |
| server_name domain.com www.domain.com; | |
| access_log /dev/null; | |
| if ($request_method !~ ^(GET|HEAD|POST)$ ) { | |
| return 444; | |
| } | |
| location ^~ /.well-known/acme-challenge/ { |
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/sh | |
| opkg update | |
| for ipk in $(opkg list-upgradable | awk '$1!~/^kmod|^Multiple/{print $1}'); do | |
| opkg upgrade $ipk | |
| done |
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
| { | |
| "apps": [{ | |
| "name": "app-service", | |
| "script": "server/index.js", | |
| "watch": true, | |
| "log_date_format": "YYYY-MM-DD HH:mm Z", | |
| "instances": 2, | |
| "ignoreWatch": ["[\\/\\\\]\\./", "node_modules"], | |
| "merge_logs": true, | |
| "exec_interpreter": "./node_modules/.bin/babel-node", |
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 | |
| today=$(date +%Y%m%d%H%M%S) | |
| log_file="./release/logs/release_${today}.log" | |
| Publish(){ | |
| app_name=$1 platform=$2 varsion=$3 | |
| react-native bundle --platform ${platform} --entry-file index.${platform}.js --bundle-output ./release/${platform}/main.jsbundle --assets-dest ./release/${platform} --dev false | |
| code-push release ${app_name} ./release/${platform}/main.jsbundle ${varsion} | |
| } |
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
| # @A Shen | |
| #!/bin/bash | |
| ## 基本配置 | |
| # 数据来源 | |
| base_host="host_url" | |
| base_db="db_name" | |
| # 导入目标 | |
| dev_host="host_url" | |
| dev_db="db_name" |
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 | |
| SCRIPT_DIR="/root" | |
| DATE_TIME=$(date +%Y%m%d%H%M) | |
| TMP_FILE="$HOSTNAME-$DATE_TIME.tar.gz" | |
| BACKUP_SRC="/etc/nginx /data/www /data/docker/gogs" #备份文件,多个用空格隔开 | |
| QINIU_BUCKET="buck_name" | |
| echo "打包文件中..." | |
| tar cfzP "$TMP_FILE" $BACKUP_SRC | |
| echo "打包完成, 上传到七牛云存储..." | |
| $SCRIPT_DIR/qshell rput "$QINIU_BUCKET" "backup/$TMP_FILE" $TMP_FILE true |
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 | |
| set -e | |
| # Add acme user if not exists | |
| if ! id "acme" &>/dev/null; then | |
| echo "Creating acme user..." | |
| sudo useradd -r -m -d /var/lib/acme -s /usr/sbin/nologin acme | |
| sudo chmod 700 /var/lib/acme | |
| else | |
| echo "User acme already exists, skipping creation..." |
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
| // .stglobalignore | |
| // Syncthing Ignore Patterns - https://docs.syncthing.net/users/ignoring.html#patterns: | |
| // Useful .stignore Patterns - https://goo.gl/DVHI1h | |
| // Usage: Add the line below to all .stignore files for each Syncthing node | |
| // #include .stglobalignore | |
| // Incomplete Downloads | |
| // Firefox downloads | |
| *.part |