- after migration - you will have to manualy replace mysql credentials
- make PHP max_execution_time to something like 3600 (1 hour)
| /** | |
| * @author Jokūbas Ramanauskas | |
| * @since 2015-03-26 | |
| * | |
| * Fetches postcode by given address information | |
| * | |
| * @return bool | |
| */ | |
| public function getPostCodeByAddress() | |
| { |
| <?php | |
| /** | |
| * Lietuviškų vardų linksniai. | |
| * | |
| * @author Dainius Kaupaitis <dainius at kaupaitis dot lt> | |
| * @copyright Copyleft (ↄ) 2011, Dainius Kaupaitis | |
| * @version 1.0 | |
| * @package Vardai | |
| */ |
| <?php | |
| /* | |
| Install: | |
| 1) create a folder: disablecsrf inside 'plugins/' directory. | |
| 2) place this file there and name it: disablecsrf.php | |
| 3) go to config/config.inc.php, and add it to plugins, like: | |
| $config['plugins'] = array('disablecsrf'); | |
| CSRF should now be disabled for login. | |
| */ |
| function youtube_get_id($url) | |
| { | |
| $pattern = | |
| '%^# Match any youtube URL | |
| (?:https?://)? # Optional scheme. Either http or https | |
| (?:www\.)? # Optional www subdomain | |
| (?: # Group host alternatives | |
| youtu\.be/ # Either youtu.be, | |
| | youtube\.com # or youtube.com |
| Package: libapache2-mod-php5 libapache2-mod-php5filter | |
| Pin: version 5.2* | |
| Pin-Priority: 1001 | |
| Package: php5-suhosin | |
| Pin: version 0.9.2* | |
| Pin-Priority: 1001 | |
| Package: php5 php5-cgi php5-cli php5-common php5-curl php5-dbg php5-dev php5-enchant php5-gd php5-gmp php5-ming php5-xcache | |
| Pin: version 5.2* |
| --- | |
| ip: "192.168.10.10" | |
| memory: 2048 | |
| cpus: 2 | |
| authorize: D:/ssh_keys/id_rsa.pub | |
| keys: | |
| - D:/ssh_keys/id_rsa |
| upstream mailcatcher { | |
| sticky; | |
| server appserver.domain.ch:3000 max_fails=1 fail_timeout=2s; | |
| } | |
| server { | |
| listen 80; | |
| server_name mailcatcher.domain.ch; | |
| client_max_body_size 4G; | |
| keepalive_timeout 5; |
| #!/usr/bin/env bash | |
| if [[ -z "$1" ]]; then | |
| echo "example usage: /usr/local/bin/vhost_add.sh acme"; | |
| exit; | |
| fi | |
| block="server { | |
| server_name $1.avek.eu; | |
| root /var/www/vhosts/$1/web; |
| [server] | |
| # on SSD do we need it? | |
| tmpdir=/ram/mysql | |
| tmp_table_size=2K | |
| # runtime edit: | |
| #set global net_buffer_length=1000000; | |
| #set global max_allowed_packet=1000000000; | |
| max_allowed_packet=100M |