Skip to content

Instantly share code, notes, and snippets.

View asamofal's full-sized avatar
🇺🇦

Anton Samofal asamofal

🇺🇦
View GitHub Profile
@dshadow
dshadow / preseed.cfg
Last active November 12, 2019 10:32
preseed.cfg
d-i debian-installer/locale string uk_UA
d-i localechooser/supported-locales multiselect en_US.UTF-8, en_US
d-i keymap select ua
d-i keyboard-configuration/modelcode string pc105
d-i keyboard-configuration/toggle select Alt+Shift
d-i keyboard-configuration/layoutcode string us,ru,ua
d-i keyboard-configuration/xkb-keymap select ua
@holmberd
holmberd / php-pools.md
Last active June 28, 2024 14:43
Adjusting child processes for PHP-FPM (Nginx)

Adjusting child processes for PHP-FPM (Nginx)

When setting these options consider the following:

  • How long is your average request?
  • What is the maximum number of simultaneous visitors the site(s) get?
  • How much memory on average does each child process consume?

Determine if the max_children limit has been reached.

  • sudo grep max_children /var/log/php?.?-fpm.log.1 /var/log/php?.?-fpm.log
@ultim8k
ultim8k / vim-multiline-comment.md
Last active June 19, 2024 21:53
(un) comment multiple lines vim

From: http://stackoverflow.com/questions/1676632/whats-a-quick-way-to-comment-uncomment-lines-in-vim

For those tasks I use most of the time block selection.

Put your cursor on the first # character, press Ctrl``V (or Ctrl``Q for gVim), and go down until the last commented line and press x, that will delete all the # characters vertically.

For commenting a block of text is almost the same: First, go to the first line you want to comment, press Ctrl``V, and select until the last line. Second, press Shift``I``#``Esc (then give it a second), and it will insert a # character on all selected lines. For the stripped-down version of vim shipped with debian/ubuntu by default, type : s/^/# in the second step instead.

@idecardo
idecardo / homestead-manual-install.md
Last active November 16, 2023 08:34
Laravel Homestead Manual Installation

Getting Started

Laravel Homestead is an official, pre-packaged Vagrant box that provides you a wonderful development environment without requiring you to install PHP, HHVM, a web server, and any other server software on your local machine. Read more...

Download

Download homestead box: