On the server, edit the file /etc/ssh/sshd_config:
ClientAliveInterval 30
ClientAliveCountMax 10
| #!/bin/bash | |
| # Secure OpenVPN server installer for Debian, Ubuntu, CentOS and Arch Linux | |
| # https://github.com/Angristan/OpenVPN-install | |
| if [[ "$EUID" -ne 0 ]]; then | |
| echo "Sorry, you need to run this as root" | |
| exit 1 | |
| fi |
| # Generated by iptables-save v1.4.14 on Wed May 14 23:43:26 2014 | |
| *filter | |
| :INPUT ACCEPT [0:0] | |
| :FORWARD ACCEPT [0:0] | |
| :OUTPUT ACCEPT [0:0] | |
| # accept all loop traffic, discard all malicious localloop traffic | |
| -A INPUT -i lo -j ACCEPT | |
| -A INPUT -d 127.0.0.0/8 ! -i lo -j REJECT --reject-with icmp-port-unreachable |
| # iptables basic rules to use (in order) | |
| # set default policy to drop | |
| iptables -P INPUT DROP | |
| iptables -P OUTPUT ACCEPT | |
| iptables -P FORWARD ACCEPT | |
| # enable ssh on port 22 | |
| iptables -A INPUT -p tcp -m tcp --dport 22 -j ACCEPT |
| from flask import Flask, request, jsonify, json, abort | |
| from flask_cors import CORS, cross_origin | |
| import pandas as pd | |
| app = Flask(__name__) | |
| cors = CORS(app) | |
| app.config['CORS_HEADERS'] = 'Content-Type' |
Install OpenCV 4.1.2 on Raspbian Buster
$ chmod +x *.sh
$ ./download-opencv.sh
$ ./install-deps.sh
$ ./build-opencv.sh
$ cd ~/opencv/opencv-4.1.2/build
$ sudo make install| #Script to install Opencv 3.4.4 with optmizations for raspberry pi that can increase performance up to 50%! | |
| #install pre-requisites | |
| sudo apt-get install build-essential checkinstall cmake pkg-config yasm git gfortran libjpeg-dev libjasper-dev libpng-dev libtiff5-dev libtiff-dev libavcodec-dev libavformat-dev libswscale-dev libdc1394-22-dev libxine2-dev libv4l-dev libgstreamer0.10-dev libgstreamer-plugins-base0.10-dev libgtk2.0-dev libtbb-dev qt5-default libatlas-base-dev libmp3lame-dev libtheora-dev libvorbis-dev libxvidcore-dev libx264-dev libopencore-amrnb-dev libopencore-amrwb-dev libavresample-dev x264 v4l-utils libprotobuf-dev protobuf-compiler libgoogle-glog-dev libgflags-dev libgphoto2-dev libeigen3-dev libhdf5-dev doxygen | |
| #add symlink for libv4l | |
| sudo ln -s -f /usr/include/libv4l1-videodev.h /usr/include/linux/videodev.h | |
| #download and install Intel TBB precompiled for raspberry pi 2/3 b | |
| git clone https://github.com/abhiTronix/TBB_Raspberry_pi.git | |
| cd TBB_Raspberry_pi/ |
Overview:
Assuming Fedora 23.