Skip to content

Instantly share code, notes, and snippets.

View alexey-vostrikov's full-sized avatar
🎪

Alexey Vostrikov alexey-vostrikov

🎪
View GitHub Profile
ok: [msk-dtln-elk0] => {
"23Gi | 8 Intel(R) Xeon(R) Gold 6226R CPU @ 2.90GHz | sda 3T"
ok: [msk-dtln-elkw2] => {
"62Gi | 16 Intel(R) Xeon(R) Gold 6226R CPU @ 2.90GHz | sda 12T"
ok: [msk-dtln-elkmon1] => {
"62Gi | 4 Intel(R) Xeon(R) Gold 6226R CPU @ 2.90GHz | sda 1T"
ok: [msk-dpro-elk3] => {
"62Gi | 16 Intel(R) Xeon(R) CPU E5-2697 v4 @ 2.30GHz | sda 4T"
ok: [msk-dtln-elkw1] => {
"62Gi | 16 Intel(R) Xeon(R) Gold 6226R CPU @ 2.90GHz | sda 11.4T"
@alexey-vostrikov
alexey-vostrikov / upgrade_livepeer.sh
Created October 18, 2022 20:23 — forked from Strykar/upgrade_livepeer.sh
Upgrade Livepeer Go binaries. Run as: $ upgrade_livepeer.sh 4efbda6d5e6586e7eb1e6ccbd526da65cdbe2e4e27a01cb76b1f2893fe790fdb
#!/bin/bash
# Update Livepeer binary from Github
# Expects bash, jq, curl, grep, sed, sha256sum and tar to be installed, usually available even on embedded systems
# Windows Subsystem for Linux (WSL) or Cygwin should provide every utility on Windows
set -e
# Requires you to specify _ostype and the path to the existing install in _lptdir below
# Do not append the directory created by the tar.gz like livepeer-linux-amd64 or livepeer-windows-amd64
### User config starts
#!/bin/bash
# sudo apt install jq wget curl
# usage: github-install user/repo
set -e
repo=$1
tmp="/tmp/.github-install"
binpath="$HOME/.local/bin"
rm -rf $tmp
@alexey-vostrikov
alexey-vostrikov / vpn-openconnect-connect-to-cisco-anyconnect.md
Created October 5, 2022 12:32 — forked from stefancocora/vpn-openconnect-connect-to-cisco-anyconnect.md
Split tunneling with openconnect - A guide on how to use openconnect to establish a vpn connection to an enterprise cisco anyconnect vpn endpoint with client side routing.

Introduction

The purpose of this short howto is to show you how to:

  • use openconnect [1] to connect to an enterprise cisco anyconnect endpoint
  • whilst minimizing the amount of traffic that your route through the vpn connection

Usually VPN administrators will puth the default route to the users, so that all user traffic is routed through the vpn connection. This is to address the various security concerns around compromised user computers bridging external internet traffic into the secure VPN network.

While the VPN administrator can push routes to the clients, the client can ignore these default routes and establish client side routing so that only the required A.B.C.D/E network is routed through the VPN. All other traffic will still use the clients default route and default outbound internet connection.

@alexey-vostrikov
alexey-vostrikov / README.md
Created October 5, 2022 12:06 — forked from merqlove/README.md
ESIA gost certs

Требования

  1. Алгоритм формирования электронной подписи должен быть RS256 (указывается в настройках ИС на технологическом портале).

Как запустить пример

Для ОС Windows 10 необходимо установить Windows Subsystem for Linux и Ubuntu 18.04 в нём.
Действия выполняются внутри терминала этой ОС.
Для ОС Windows Server 2008 R2 необходимо установить OpenSSL 1.1.1g Win64. А также установить библиотеку gost.dll сборка и настройка по инструкции

@alexey-vostrikov
alexey-vostrikov / trial.md
Created September 29, 2022 18:54 — forked from satish-setty/trial.md
Beyond Compare 4 license for Linux

Beyond Compare 4.x

Licensed to: ASIO Allsoftinone Quantity: 1 user Serial number: 1822-9597 License type: Pro Edition for Linux

First delete away trial mode:

sudo sed -i "s/keexjEP3t4Mue23hrnuPtY4TdcsqNiJL-5174TsUdLmJSIXKfG2NGPwBL6vnRPddT7tH29qpkneX63DO9ECSPE9rzY1zhThHERg8lHM9IBFT+rVuiY823aQJuqzxCKIE1bcDqM4wgW01FH6oCBP1G4ub01xmb4BGSUG6ZrjxWHJyNLyIlGvOhoY2HAYzEtzYGwxFZn2JZ66o4RONkXjX0DF9EzsdUef3UAS+JQ+fCYReLawdjEe6tXCv88GKaaPKWxCeaUL9PejICQgRQOLGOZtZQkLgAelrOtehxz5ANOOqCaJgy2mJLQVLM5SJ9Dli909c5ybvEhVmIC0dc9dWH+/N9KmiLVlKMU7RJqnE+WXEEPI1SgglmfmLc1yVH7dqBb9ehOoKG9UE+HAE1YvH1XX2XVGeEqYUY-Tsk7YBTz0WpSpoYyPgx6Iki5KLtQ5G-aKP9eysnkuOAkrvHU8bLbGtZteGwJarev03PhfCioJL4OSqsmQGEvDbHFEbNl1qJtdwEriR+VNZts9vNNLk7UGfeNwIiqpxjk4Mn09nmSd8FhM4ifvcaIbNCRoMPGl6KU12iseSe+w+1kFsLhX+OhQM8WXcWV10cGqBzQE9OqOLUcg9n0krrR3KrohstS9smTwEx9olyLYppvC0p5i7dAx2deWvM1ZxKNs0BvcXGukR+/g" /usr/lib/beyondcompare/BCompare
@alexey-vostrikov
alexey-vostrikov / gitconfig.md
Created September 29, 2022 18:19 — forked from ffittschen/gitconfig.md
Use IntelliJ or WebStorm as git mergetool with SourceTree

Use IntelliJ or WebStorm as git mergetool

Configure Sourcetree

The merge tool that ships with JetBrain's IntelliJ IDEA or WebStorm is really awesome and way better than FileMerge. It is quite simple to configure SourceTree to use it as the default mergetool:

  1. Open the SourceTree preferences and select the Diff tab
  2. Choose Custom both as Visual Diff Tool and as Merge Tool
  3. Paste the following commands into the textfields:
  • Diff Command: /Applications/IntelliJ\ IDEA.app/Contents/MacOS/idea diff
@alexey-vostrikov
alexey-vostrikov / GoogleAuthenticationCurl.sh
Created September 12, 2022 17:06 — forked from LindaLawton/GoogleAuthenticationCurl.sh
Curl bash script for getting a Google Oauth2 Access token
# Tutorial https://www.daimto.com/how-to-get-a-google-access-token-with-curl/
# YouTube video https://youtu.be/hBC_tVJIx5w
# Client id from Google Developer console
# Client Secret from Google Developer console
# Scope this is a space seprated list of the scopes of access you are requesting.
# Authorization link. Place this in a browser and copy the code that is returned after you accept the scopes.
https://accounts.google.com/o/oauth2/auth?client_id=[Application Client Id]&redirect_uri=urn:ietf:wg:oauth:2.0:oob&scope=[Scopes]&response_type=code
# Exchange Authorization code for an access token and a refresh token.
fio --randrepeat=1 --ioengine=libaio --direct=1 --gtod_reduce=1 --name=fiotest --filename=testfio --bs=4k --iodepth=64 --size=8G --readwrite=randrw --rwmixread=50
fio --randrepeat=1 --ioengine=libaio --direct=1 --gtod_reduce=1 --name=fiotest --filename=fiotest --bs=4k --iodepth=64 --size=8G --readwrite=randwrite
exec &> >(tee -a "$log_file")
echo "This will be logged to the file and to the screen"