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
# Tested on Debian 10 (Buster) | |
wget https://curl.se/download/curl-7.77.0.zip | |
unzip curl-7.77.0.zip | |
cd curl-7.77.0 | |
sudo apt-get build-dep curl | |
sudo apt-get install build-essential | |
sudo apt-get install libcunit1-dev libssl-dev libev-dev libevent-dev libjansson-dev libjemalloc-dev | |
sudo apt-get install libssh2-1-dev | |
sudo apt-get install zlib1g zlib1g-dev |
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
# Requirements | |
# debian/ubuntu | |
apt-get -y update && apt-get -y upgrade | |
apt-get -y install strongswan xl2tpd libstrongswan-standard-plugins libstrongswan-extra-plugins | |
# Setup variables for L2TP connestion | |
VPN_SERVER_IP='' | |
VPN_IPSEC_PSK='' | |
VPN_USER='' |
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
<?php | |
/** | |
* Curl testing stub | |
*/ | |
$url = ''; | |
$userAgent = 'User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.111 Safari/537.36'; | |
$headers = array(); |
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
<?php | |
/** | |
* Disable/Enable foreign key checkin for different drivers | |
* | |
* Usage: | |
* 1. Save the trait to app/Traits/DisablesForeignKeys.php | |
* 2. Add use statement in database/seeds/DatabaseSeeder.php: | |
* use App\Traits\DisablesForeignKeys; | |
* 3. Add use to class definition: | |
* class DatabaseSeeder extends Seeder |
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 | |
# | |
# Automate mysql secure installation for debian-baed systems | |
# | |
# - You can set a password for root accounts. | |
# - You can remove root accounts that are accessible from outside the local host. | |
# - You can remove anonymous-user accounts. | |
# - You can remove the test database (which by default can be accessed by all users, even anonymous users), | |
# and privileges that permit anyone to access databases with names that start with 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
# Чтобы не вводить пароль при каждом повышении привилигей (sudo -s) необходимо | |
# 1. В файл sudoers нужно добавить стоку. | |
# 2. Изменить <username> на реальное имя пользователя в системе | |
# Примечание. В FreeBSD полный путь к файлу — /usr/local/etc/sudoers, в Linux Ubuntu — /etc/sudoers. | |
<username> ALL=(ALL) NOPASSWD: ALL |