This file contains 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 | |
# this script creates an IPIP Tunnel | |
# tested for CENTOS 6 & 7 | |
#---------------------------- | |
# CONFIGURATION | |
#---------------------------- | |
# name of tunnel | |
name='tun_test' |
This file contains 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 | |
#only test for centos 7 | |
MYSQL_SERIES=8.0 | |
MYSQL_VERSION=8.0.29 | |
MYSQL_DOWNLOAD_URL=https://dev.mysql.com/get/Downloads/MySQL-${MYSQL_SERIES}/mysql-${MYSQL_VERSION}-el7-x86_64.tar.gz | |
MYSQL_INSTALL_DIR=/usr/local/mysql | |
MYSQL_SOURCE_DIR="${MYSQL_INSTALL_DIR}-${MYSQL_VERSION}" | |
MYSQL_DATA_DIR=/var/lib/mysql | |
MYSQL_LOG_DIR=/var/log/mariadb | |
DEFAULT_ROOT_PASSWORD=123456789 |
This file contains 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 | |
#test only centos7 | |
REDIS_INSTALL_DIR=/usr/local/redis | |
REDIS_TMP_DIR=/tmp/redis | |
function check_error() { | |
if [ $? -ne 0 ]; then | |
echo $1 | |
remove | |
exit 1 | |
fi |
This file contains 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 | |
VERSION=v1.20.1 | |
INSTALL_DIR=/usr/local/syncthing | |
TMP_DIR=/tmp/syncthing | |
HOME_DIR=/etc/syncthing | |
function check_error() { | |
if [[ $? -ne 0 ]]; then | |
echo $1 | |
exit 1 | |
fi |
This file contains 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 | |
#elasticsearch 8.2.0 | |
#test only centos7 | |
ES_DOWNLOAD_URL=https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-8.2.0-linux-x86_64.tar.gz | |
ES_INSTALL_DIR=/usr/local/elasticsearch | |
ES_TMP_DIR=/tmp/elasticsearch | |
REQUIRED_SOFTWARE_LIST=(wget tar sed) | |
#perl-Digest-SHA | |
function check_software() { | |
check_software_bool $1 |
This file contains 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 | |
RELEASE_API="https://api.github.com/repos/net-byte/vtun/releases/latest" | |
BIN_DST_DIR=/usr/local/bin | |
RESOURCE_DST_DIR=/usr/local/etc/vtun | |
CIDR_V4="192.168.90.0/24" | |
CIDR_V6="fced:9999::/64" | |
SIP_V4="192.168.90.1" | |
SIP_V6="fced:9999::1" | |
RUNNING_LISTENER="127.0.0.1:8002" | |
DEFAULT_KEY="defaultkey" |
This file contains 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 | |
VERSION="2.1.0" | |
DOWNLOAD_URL="https://github.com/alibaba/nacos/releases/download/${VERSION}/nacos-server-${VERSION}.tar.gz" | |
INSTALL_DIR=/usr/local/nacos-server-${VERSION} | |
LINK_PATH=/usr/local/nacos | |
TMP_DIR=/tmp/nacos | |
function check_error() { | |
if [ $? == 1 ]; then | |
echo $1 |
This file contains 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
package main | |
import ( | |
"bytes" | |
"fmt" | |
"io" | |
"net/http" | |
"time" | |
"github.com/gin-gonic/gin" |
This file contains 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
https://unix.stackexchange.com/questions/125382/migrate-socat-init-script-to-systemd | |
For socat, I use a pure systemd approach. This is an example for a serial loopback: | |
[Unit] | |
Description=Socat Serial Loopback | |
#Before=my-other.service | |
[Service] | |
Type=simple |
OlderNewer