Skip to content

Instantly share code, notes, and snippets.

View k-zakhariy's full-sized avatar
🔥

Zakhariy k-zakhariy

🔥
View GitHub Profile
@k-zakhariy
k-zakhariy / laravel_folder_perm.md
Last active August 2, 2021 09:00
Laravel folder permissions
sudo chown -R USERNAME:USERNAME /path/to/laravel
sudo find /path/to/laravel -type f -exec chmod 644 {} \;
sudo find /path/to/laravel -type d -exec chmod 755 {} \;
cd /path/to/laravel
sudo chgrp -R www-data storage bootstrap/cache
sudo chmod -R ug+rwx storage bootstrap/cache
sudo usermod -a -G www-data USERNAME
@k-zakhariy
k-zakhariy / atomScan.md
Last active July 4, 2023 10:35
AtomScan Manual - personal nuclear radiation meter geiger counter

Configure

xdebug.ini

xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_port=9000
xdebug.remote_autostart=1
xdebug.remote_connect_back=1
@k-zakhariy
k-zakhariy / ffmpeg-avchd-conversion.md
Created May 11, 2018 11:48 — forked from trisweb/ffmpeg-avchd-conversion.md
ffmpeg commands for converting AVCHD-Lite video to better format(s)

FFMpeg Commands for Transcoding MTS video (from AVCHD-Lite Cameras, like Panasonic DMC-TS1/2)

720p -> H.264 (x264) video + AAC 128kbps audio:

Medium quality 720p:

ffmpeg -i 00001.MTS -threads 3 -y -vcodec libx264 -sameq -acodec libfaac -ab 128k -ar 44100 -ac 2 -s 1280x720 -vpre normal -b 1M output.mp4

High quality 720p:

@k-zakhariy
k-zakhariy / ffmpeg-avchd-conversion.md
Created May 11, 2018 11:48 — forked from trisweb/ffmpeg-avchd-conversion.md
ffmpeg commands for converting AVCHD-Lite video to better format(s)

FFMpeg Commands for Transcoding MTS video (from AVCHD-Lite Cameras, like Panasonic DMC-TS1/2)

720p -> H.264 (x264) video + AAC 128kbps audio:

Medium quality 720p:

ffmpeg -i 00001.MTS -threads 3 -y -vcodec libx264 -sameq -acodec libfaac -ab 128k -ar 44100 -ac 2 -s 1280x720 -vpre normal -b 1M output.mp4

High quality 720p:

@k-zakhariy
k-zakhariy / install_ffmpeg_libfdkaac.sh
Created February 8, 2018 17:55 — forked from rafaelbiriba/install_ffmpeg_libfdkaac.sh
Install FFmpeg with libfdk_aac support (For Ubuntu)
# Criando um script .sh para executar todos os comandos:
#root@servidor:~# vi script.sh
#root@servidor:~# chmod +x script.sh
#root@servidor:~# ./script.sh
apt-get update
apt-get -y install autoconf automake build-essential git-core libass-dev libgpac-dev libsdl1.2-dev libtheora-dev libtool libvdpau-dev libvorbis-dev libx11-dev libxext-dev libxfixes-dev pkg-config texi2html zlib1g-dev libmp3lame-dev nasm gcc yasm && true
mkdir ~/ffmpeg_sources
cd ~/ffmpeg_sources
git clone --depth 1 git://github.com/mstorsjo/fdk-aac.git
@k-zakhariy
k-zakhariy / gist:cee15355e4d99f1498d8ff57eeefd773
Last active November 28, 2017 18:56
Setup vsftpd Ubuntu 15.10

Setup vsftpd for Ubuntu 15.10

First you need vsftp and PAM installed

apt-get install vsftpd libpam-pwdfile Edit /etc/vsftpd.conf

nano /etc/vsftpd.conf then paste in the following

listen=YES
@k-zakhariy
k-zakhariy / mongodb_backup.md
Created August 1, 2016 21:36 — forked from baniol/mongodb_backup.md
MongoDB automatic backup

Maintaining even a small mongodb application in production requires regular backups of remotely stored data. MongoDB gives you three ways to acomplish it. In this post I'm using monogodump command for creating a backup and mongorestore for recreating the data. The purpose of this writing is to provide a simple way of periodic database dumps from a remote server to a Dropbox cloud storage.

Remember that for using mongodump you have to have a mongod process running.

Dumping a database

Suppose that you want make a backup of your books database.

To create a dump use mongodump -d books -o which will result in a book folder containing bson files with all collections.