Skip to content

Instantly share code, notes, and snippets.

Avatar

Manu Louisor floptwo

View GitHub Profile
@floptwo
floptwo / query.sql
Last active May 12, 2020
Change MySQL 5.7 Password and Server authentication plugin for root user
View query.sql
SELECT user,authentication_string,plugin,host FROM mysql.user;
UPDATE mysql.user SET plugin = 'mysql_native_password', authentication_string = PASSWORD('mypassword') WHERE User = 'root';
FLUSH PRIVILEGES;
@floptwo
floptwo / form-floating-label.scss
Last active May 14, 2020
A SCSS (Sass) version of the Bootstrap 4 floating-labels.css from https://getbootstrap.com/docs/4.0/examples/floating-labels/
View form-floating-label.scss
// A SCSS (Sass) version of the floating-labels.css from https://getbootstrap.com/docs/4.0/examples/floating-labels/
.form-label-group {
margin-bottom: 1rem;
position: relative;
& > input,
& > textarea,
& > label {
padding: #{$input-btn-padding-y} #{$input-btn-padding-x};
@floptwo
floptwo / gist:b2fd1010e6a0d0e97c9f3bea3c74c88b
Last active May 6, 2020
Let's Encrypt (certbot) add new domain to existing configuration
View gist:b2fd1010e6a0d0e97c9f3bea3c74c88b
certbot --nginx --expand -d example.com,www.example.com,blog.example.com
@floptwo
floptwo / Envoy.blade.php
Last active Oct 2, 2017
envoy run deploy (no downtime)
View Envoy.blade.php
@setup
$server = 'myserver';
$repository_path = "~/git/myapp.git";
$application_path = "~/webroot/myapp.com/www";
$env = $env ?? 'production';
$branch = $branch ?? 'master';
$branch = ($env == 'production') ? 'production' : $branch;
$shared_dirs = [
@floptwo
floptwo / composer_ovh.md
Last active Oct 2, 2018
Install Composer OVH Mutu
View composer_ovh.md
curl -sS https://getcomposer.org/installer | /usr/local/php7.0/bin/php
mkdir bin
mv composer.phar bin/composer
/usr/local/php7.0/bin/php ~/bin/composer
View Code postaux Antilles-Guyane
<?php
// Code postaux des villes des Antilles-Guyane
// Sources :
// http://fr.wikipedia.org/wiki/Liste_des_communes_de_la_Guadeloupe
// http://fr.wikipedia.org/wiki/Liste_des_communes_de_la_Guyane
// http://fr.wikipedia.org/wiki/Liste_des_communes_de_la_Martinique
$villes = [
// Guadeloupe
View php-cli_ovh_mutu.md

PHP-CLI (PHP en ligne de commande) sur les hébergements mutualisés OVH

More complete info here http://cluster015.ovh.net/infos/ (thanks to @42antoine)

(cli)

/usr/local/php5.3/bin/php => PHP 5.3.29 (cli) (built: Nov 21 2017 08:55:07)
/usr/local/php5.4/bin/php => PHP 5.4.45 (cli) (built: Nov 21 2017 08:35:51)
/usr/local/php5.5/bin/php => PHP 5.5.38 (cli) (built: Nov 21 2017 08:46:45)
You can’t perform that action at this time.