← Înapoi la Urmăritori

Cel mai recent articol

Ultima verificare

Urmăritori 0 urmăritori
Articole: 136
  1. Creating Wildcard SSL Certificates with Let’s Encrypt

    Install certbot: wget https://dl.eff.org/certbot-auto chmod a+x .

  2. Reinstall all packages with --force on Arch

    Here is simple solution pacman -Qqen > pkglist.txt pacman --force -S $(< pkglist.txt) mkinitcpio -p linux

  3. Create an encrypted file container with dm-crypt

    Create an empty file with the size of your container dd if=/dev/zero bs=1M count=100 of=~/my-container.img Here I’ll use a 100MB container Initialise the LUKS partition on the file and set the initial passphrase. cryptsetup luksFormat ~/mycontainer Open t…

  4. Building windows go programs on linux

    $ cat hello.go package main import "fmt" func main() { fmt.Printf("Hello\n") } $ GOOS=windows GOARCH=386 go build -o hello.exe hello.go

  5. Rename a part of filename of a bunch of files

    Example $ ls -l AndroidTest.pdf Angular2Test.pdf BashTest.pdf The simplest way to remove ‘Test’ from any files: rename 's/Test//g' *.pdf $ ls -l Android.pdf Angular2.pdf Bash.pdf Or change ‘Test’ to ‘Hello’ rename 's/Test/Hello/g' *.pdf $ ls -l AndroidTes…

  6. Switch PHP version

    From php5.6 to php7.0: Apache: sudo a2dismod php5.6 ; sudo a2enmod php7.0 ; sudo service apache2 restart CLI: sudo update-alternatives --set php /usr/bin/php7.0 From php7.0 to php5.6: Apache: sudo a2dismod php7.0 ; sudo a2enmod php5.6 ; sudo service apach…

  7. Jak ugotować jajko idealne

    Ważne jest, by jajka osiągnęły temperaturę pokojową, zanim zaczniemy je gotować.

  8. Open PowerShell with Administrator Privileges and type: check the path to your openvpn.exe!

  9. A puzzle for 5 bitcoins

    A few years ago a multilevel puzzle was published, in which there were 4.87 BTCs to win, now it was the last level and collected already 5BTC, calculated at the current rate of over $62770.00.

  10. Remove all of the diacritics from a file

    I like iconv as it handles all accents variations : cat non-ascii.txt | iconv -f utf8 -t ascii//TRANSLIT//IGNORE > ascii.txt

  11. Facebook watches our messages from messenger.

    How to get a 72h ban in a second after sending a message.

  12. Configure mosquitto to use websockets

    Add the following lines to /etc/mosquitto/mosquitto.conf in the “Default Listener” section: port 1883 listener 9001 protocol websockets

  13. Docker - How to cleanup (unused) resources

    Once in a while, you may need to cleanup resources (containers, volumes, images, networks) … delete volumes // see: https://github.com/chadoe/docker-cleanup-volumes $ docker volume rm $(docker volume ls -qf dangling=true) $ docker volume ls -qf dangling=t…

  14. fun with a friend's postcard

    encryption of the message into zlib from codecs import encode from functools import reduce print reduce(encode, ('utf8', 'zlib', 'hex'), "this is my message on the postcard") #output: 789c2bc9c82c5600a2dc4a85dcd4e2e2c4f45485fc3c85928c548582fce292e4c4a2140…

  15. Dysleksja

    Przyjaciel z dysleksją opisał mi, jak odczuwa czytanie lektury.

  16. Radio station with RDS function on Raspberry Pi

    Today I will demonstrate you how to install the FM radio transmitter on Raspberry Pi.

  17. Convert Mercurial project to Git

    I’m using fast-export: cd ~ git clone https://github.com/frej/fast-export.git git init git_repo cd git_repo ~/fast-export/hg-fast-export.sh -r /path/to/old/mercurial_repo git checkout HEAD source: https://stackoverflow.com/questions/16037787/convert-mercu…

  18. Simple start with YOLO v2

    reduce frames to 15 per sec: # ffmpeg -i stepup.mp4 -r 15 stepup15.mp4 make new directory for frames and put to stepup/ a video to split #mkdir stepup/; mkdir yolo_stepup/ split to frames: # ffmpeg -i stepup15.mp4 stepup_%04d.png lets begin the games!

  19. Useful keyboard shortcuts for terminal

    Terminal clipboard, check it out :) ctrl + u = Cut to the clipboard ctrl + y = Paste from the clipboard

  20. Debian 9: Change the network from enp3s0 to eth0

    nano /etc/udev/rules.d/10-network.rules SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="08:00:27:a6:ad:0e", NAME="eth0" SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="08:00:27:6e:77:cc", NAME="wlan0" then reboot.

  21. 1998 vs 2017

    1998: Don’t get into strangers’s cars Don’t meet people from the internet 2017: Literally summon strangers from the internet to get into their car

  22. Quick way to add new posts in Jekyll with Python

    To make life a little easier from datetime import datetime MYPOST = """\ --- layout: post title: "{0}" date: {1} +0200 categories: {2} --- here my text """ if __name__ == "__main__": title = raw_input("Title:\n") categories = raw_input("Categories:\n") if…

  23. Mark Zuckerberg says 'Facebook has 2 billion people!'

    Mark Zuckerberg officially announced that over 2 billion people in the world have a Facebook account As of this morning, the Facebook community is now officially 2 billion people!

  24. Windows on Bash // GUI!

    Download VcXsrv (or any other X server) and run it.

  25. Nagios with Nginx

    server { listen 80; server_name my.example.com; access_log /var/log/nginx/nagios.access.log; error_log /var/log/nginx/nagios.error.log info; expires 31d; #rewrite ^/nagios3/(.*)$ /$1 break; rewrite ^/nagios3/(.*)$ /$1; root /usr/share/nagios3/htdocs; index

  26. Deploy Jekyll Blog with Git

    Local Installation Install jekyll gem install jekyll Creating a Blog Navigate to wherever you want to store your blog files on your local machine, and create a new blog like so: jekyll new awesomeblog This will create an awesomeblog directory containing t…

  27. How to edit file in a docker container?

    As in the comments, there’s no default editor set - strange - $EDITOR env variable is empty.

  28. Raspberry Alexa

    sudo raspi-config sudo apt-get update sudo apt-get upgrade sudo apt-get install git git clone git://git.drogon.net/wiringPi cd wiringPi .

  29. Roll Own VPN AdBlock Service

    It’s actually super cheap & easy.

  30. nginx + cgit + debian = one host

    root@raspberrypi:/var/www# cat /etc/nginx/sites-enabled/www server { listen 80; server_name home.control; root /var/www; index index.php index.html index.htm; location / { try_files $uri $uri/ =404; autoindex on; } location ~ \.php$ { try_files $uri =404;…

  31. Tiny IRC Doc

    .post-content ul {list-style: none;} NickServ Register nickname on server: /nick YourNick /msg NickServ REGISTER YourPassword youremail@example.com Login /msg NickServ IDENTIFY YourNick YourPassword Logging In /connect chat.freenode.net 6697 YourNick:Your…

  32. Run programs in the screen at startup using systemd

    systemd is very simple and easy to use, here you can see how to run the program in a screen with the specified user create new file nano /etc/systemd/system/radio.service and put it into a new file [Unit] Description=Radio DJ After=network.target [Service]

  33. Nginx configuration for SSH tunnel

    upstream tunnel { server 127.0.0.1:3000; } server { listen 80; server_name dev.server.tld www.dev.server.tld; #optional location / { proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host

  34. ffmpeg on Raspbian - Raspberry Pi

    First for all we need to build and install x264 git clone --depth 1 git://git.videolan.org/x264 cd x264 .

  35. Gateway VPN - Raspberry Pi Router

    # nano /etc/sysctl.conf # net.ipv4.ip_forward=1 # sysctl -p # iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE # iptables -t nat -A POSTROUTING -o tap0 -j MASQUERADE Enable VPN at boot # systemctl enable openvpn@Japan nano /etc/default/openvpn #AUTOST…

  36. Fixing Lastpass & Firefox

    If you are having problems with your browser locking up whenever you’re entering a password perform the following change.

  37. 'Music' from /dev/urandom

    cat /dev/urandom | hexdump -v -e '/1 "%u\n"' | awk '{ split("0,2,4,5,7,9,11,12",a,","); for (i = 0; i < 1; i+= 0.0001) printf("%08X\n", 100*sin(1382*exp((a[$1 % 8]/12)*log(2))*i)) }' | xxd -r -p | aplay -c 2 -f S32_LE -r 16000

  38. Weechat BNC

    openssl s_client -connect znc.itunix.cloud:6697 </dev/null 2>/dev/null | openssl x509 -in /dev/stdin -noout -fingerprint -sha256 | sed s/://g | cut -c 20- 5A038025E789ED2F1032EB15XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX08FA693 /server add BNC znc.itunix.cloud/6697

  39. ssh tunnel to localhost

    ssh -R 9000:192.168.1.13:80 -N root@example.com

  40. Simple server backup

    sudo mount /dev/xxxx -o remount-ro /mnt mkdir /backup cd /backup tar --exclude='/backup' --exclude='/mnt/backup' --exclude='/mnt/mnt' -cvjpf mybackup.tar.bz2 /mnt tar –exclude='.

  41. Saving Iptables Firewall Rules Permanent

    run as root sudo -s Save current firewall rules to file iptables-save > /etc/firewall.conf INCLUDE ON BOOT echo '#!

  42. PHP bot to get wikipedia definitions

    <?

  43. How to configure iptables for openvpn

    If you have installed the openvpn server and iptable is blocking the service by default then use these configurations for openvpn to function properly.

  44. Firefox Language

    install your language file from here about:config -> 'general.useragent.locale': 'de' restart Firefox http://ftp.mozilla.org/pub/firefox/nightly/latest-mozilla-central-l10n/linux-x86_64/xpi/ http://ftp.mozilla.org/pub/firefox/nightly/latest-mozilla-centra…

  45. debootstrap debian chroot

    # debootstrap --arch i386 squeeze /mnt http://ftp.halifax.rwth-aachen.de/debian # chroot /mnt # apt-get install linux-image-686 # apt-get install grub2 (answer to Continue without installing GRUB?

  46. Convert directory to QEMU/KVM virtual disk image

    First, create a raw image of the required size.

  47. Applications that I use on iPhone

    I have prepared a list of applications that I use on my iPhone; the following list does not include all applications I’m using, but only those which can seem to be interesting for some of you. .appBoxs { border-bottom: 1px solid #ccc; margin-top: 10px; pa…

  48. Facebook on Tor

    Zuckerberg jealous that I have a blog with my name in the domain, decided to open his factory in onions.

  49. StopForumSpam.com -> iptables

    Start with the dependencies: apt-get install zip unzip ipset Then add this to your existing iptables firewall script: ipset create sfs_block hash:net iptables -I FORWARD -p tcp --dport 80:443 -m set --match-set sfs_block src -j DROP Then a script that upd…

  50. Compile and run OpenCV code from the command line

    For OpenCV 2.4.x cd /path/to/opencv/samples/c/ For OpenCV 3 cd /path/to/opencv/samples/cpp/ Compile g++ -ggdb `pkg-config --cflags --libs opencv` facedetect.cpp -o facedetect run .