Skip to content

Instantly share code, notes, and snippets.

View soulaway's full-sized avatar

Dmitry Soloviev soulaway

View GitHub Profile
@soulaway
soulaway / docker-wsl2.md
Created September 14, 2024 15:22 — forked from martinsam16/docker-wsl2.md
How to install wsl2 ubuntu + docker + docker-compose

Activate wsl2

dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
wsl --set-default-version 2

Install and Configure Ubuntu

@soulaway
soulaway / bootstrap.min.css
Created July 24, 2024 22:52
bootstrap.min.css
/*!
* Bootstrap v2.0.4
*
* Copyright 2012 Twitter, Inc
* Licensed under the Apache License v2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Designed and built with all the love in the world @twitter by @mdo and @fat.
*/
article, aside, details, figcaption, figure, footer, header, hgroup, nav,
sudo apt update
# 16 x 128 = 2048
sudo dd if=/dev/zero of=/swapfile bs=128M count=16
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
sudo swapon -s
sudo nano /etc/fstab >> /swapfile swap swap defaults 0 0
### Tunel remote 8080 to local 8089:
ssh -L 8089:10.122.3.6:8080 [email protected]
### Execute bash after ssh connection:
ssh -tt [email protected]<<EOT
# cd /home/theuser/pathToRemoteApp
# call mvn,ant,bash
exit
EOT
@soulaway
soulaway / gist:379be832fcc31e0332ba5a25e297de6b
Created October 15, 2023 20:38
Apache Cassandra and Solr install/setup on docker
docker pull cassandra:2.2.7
docker run --name casdb -p 127.0.0.1:9042:9042 -p 127.0.0.1:9160:9160 -d cassandra:2.2.7
# To install the default instance of Apache Solr we may pull base docker image,
# build an image with articles core inside, and then launch it linking to Cassandra
# and exposing name solrsearch and port (step 2 have to be executed from the Dockerfile location)
docker pull solr
docker build -t "solrnews" .
docker run -p 8983:8983 --name solrsearch --link casdb:cassandra -d solrnews
@soulaway
soulaway / gist:d0566a800b9f7ac4e9d9e99e8603ba9f
Created October 15, 2023 20:33
JAMES smptp server on AWS Amazon Linux 2 AMI
# JAMES smptp server on AWS Amazon Linux 2 AMI (java 11)
sudo yum update -y
sudo amazon-linux-extras install docker
sudo yum install docker
sudo service docker start
sudo usermod -a -G docker ec2-user
sudo docker info
sudo yum install git
git clone https://github.com/apache/james-project.git
@soulaway
soulaway / gist:d9af7a0af8c94f7043bfd1f77d88f9b3
Created October 15, 2023 20:32
Install Jenkins master/slave java8
# Jenkins:80:8080
#master:
#update java
sudo yum update
sudo yum install java-1.8.0-openjdk
sudo alternatives --config java
sudo yum install git -y
sudo wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo
@soulaway
soulaway / gist:622fc98bd780beddabd779a71d397511
Created October 15, 2023 20:29
Install MYSQL, JIRA, CONFLUENCE
#DB on AWS ubuntu/images/hvm-ssd/ubuntu-focal-20.04-amd64-server-20200423 (ami-05c26ae4789875080)
sudo apt install mysql-server
sudo mysql_secure_installation
>>pwd 4 root mysq
sudo nano /etc/mysql/mysql.conf.d/mysqld.cnf # change bind address to 0.0.0.0
sudo systemctl restart mysql
sudo systemctl enable mysql
ss -ltn
sudo ufw allow from any to any port 3306 proto tcp
#Manage DB
The drone is controlled via channels over one of generic frequencies: 915 MHz and 2.4 GHz.
915 stays for very long range ~20+ km but has some packet losses.
2.4 GHz. is most often used allowing mutch detailed controll on quite enough range ~10+ km.
Video stream are broadcasting at 5.8GHz
Battery allows average time of flight 5 - 30 minutes.
Book:
https://oscarliang.com/fpv-dictionary/
TV:
@soulaway
soulaway / gist:d5126897380c0e5bddb30aa9c6489d92
Created July 16, 2018 14:28 — forked from sebsto/gist:19b99f1fa1f32cae5d00
Install Maven with Yum on Amazon Linux
sudo wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo
sudo sed -i s/\$releasever/6/g /etc/yum.repos.d/epel-apache-maven.repo
sudo yum install -y apache-maven
mvn --version