add this task into crontab
* * * * * flock -xn /tmp/backup_task.lock -c '/data/shell/entry.sh > /dev/null 2>&1'
#!/usr/bin/python | |
# coding: UTF-8 | |
import urllib.request | |
import base64, json, os, time | |
import pycurl | |
sub_url = '' | |
''' | |
v: 配置文件版本号,主要用来识别当前配置 |
#!/bin/bash | |
set -xe | |
repos=( | |
"steemfans/pricefeed:latest" | |
"steemfans/authsteem:edge" | |
"steemfans/authsteem:latest" | |
"steemfans/steem-dev-tools:latest" | |
"steemfans/steem-conductor:latest" |
# Endpoint for P2P node to listen on | |
p2p-endpoint = 0.0.0.0:2001 | |
# Maxmimum number of incoming connections on P2P endpoint | |
p2p-max-connections = 200 | |
# Shared file size | |
shared-file-size = 64G | |
#shared-file-dir = /shm/ |
add this task into crontab
* * * * * flock -xn /tmp/backup_task.lock -c '/data/shell/entry.sh > /dev/null 2>&1'
#!/bin/bash | |
set -xe | |
files=`ls | grep CR2` | |
for name in $files | |
do | |
IFS='.' read -ra fn <<< "$name" | |
convert $name output/${fn[0]}.jpg |
#!/bin/bash | |
LOG_NUM=`docker logs --tail 30 steem_hivemind_seed | grep 'transactions on block' | wc -l` | |
if [ ${LOG_NUM} -ne 0 ];then | |
exit 0 | |
else | |
proxychains /usr/bin/telegram.sh "steem hivemind seed down!" | |
fi |
#!/bin/sh | |
PING=`ping -c 5 114.114.114.114|grep -v grep|grep '64 bytes' |wc -l` | |
if [ ${PING} -ne 0 ];then | |
exit 0 | |
else | |
/etc/init.d/network restart | |
fi | |
sleep 10 |
* * * * * docker ps -a -q -f status=exited | xargs --no-run-if-empty docker rm -v | |
* * * * * docker images -f "dangling=true" -q | xargs --no-run-if-empty docker rmi | |
* * * * * docker volume ls -qf dangling=true | xargs --no-run-if-empty docker volume rm |
version: '2.2' | |
services: | |
es01: | |
image: docker.elastic.co/elasticsearch/elasticsearch:7.6.0 | |
container_name: es01 | |
environment: | |
- node.name=es01 | |
- discovery.seed_hosts=es02 | |
- cluster.initial_master_nodes=es01,es02 | |
- cluster.name=docker-cluster |
Content-Type: multipart/mixed; boundary="//" | |
MIME-Version: 1.0 | |
--// | |
Content-Type: text/cloud-config; charset="us-ascii" | |
MIME-Version: 1.0 | |
Content-Transfer-Encoding: 7bit | |
Content-Disposition: attachment; filename="cloud-config.txt" | |
#cloud-config |