Skip to content

Instantly share code, notes, and snippets.

--
-- this sql structure is for knowledgebase or educational only.
-- please do this on your localhost first before ypu test on your server
--
-- @author : awan
-- @author @link http://www.nawa.me
--
-- github : https://github.com/aufa/
--
-- @description this sql is for importing the MaxminD GeoLite Country to mysql data

Problem with VirtualBox 4.3.12

It seems there is some problems between Vagrant 1.6.2 and VirtualBox 4.3.12 (the latest at the time or writing this), switching back to VirutalBox 4.3.6 or VirtualBox 4.3.8 seems to eliminate the problem.

update 1: Try both Vagrant 1.6.2 and VirtualBox 4.3.12 on Mac and they seem to work fine!

update 2: You need to enable Virtual Machine option in your BIOS to make VirtualBox work as expected. Saw someone mention about this in Laravel forum about this and it is true.

Also, Vagrant version should be 1.6.2.

Problem with VirtualBox 4.3.12

It seems there is some problems between Vagrant 1.6.2 and VirtualBox 4.3.12 (the latest at the time or writing this), switching back to VirutalBox 4.3.6 or VirtualBox 4.3.8 seems to eliminate the problem.

update 1: Try both Vagrant 1.6.2 and VirtualBox 4.3.12 on Mac and they seem to work fine!

update 2: You need to enable Virtual Machine option in your BIOS to make VirtualBox work as expected. Saw someone mention about this in Laravel forum about this and it is true.

Also, Vagrant version should be 1.6.2.

@akatche
akatche / idea.php
Last active March 23, 2016 21:41
Idea para Shoel
//tiene ingresos de una recudacion, tiene gastos del chofer, tiene gasto de la recaudacion
//tiene autos , y el chofer tiene auto
//Me voy a basar en esto que me dijiste en el caralibro
//Como vos tenes un chofer haria esto
$chofer = Chofer::find(1); //Obtengo un chofer
//El chofer, tiene viajes, por lo tanto
$viajes = $chofer->viajes; //En la variable $viajes, vos tenes todos los viajes de ese chofer
@akatche
akatche / ObtenerProtocolos.php
Created April 18, 2019 11:15
Laravel code I love. This was for a project on my current work. The requirement was to have an API call to fetch documents, but we have 3 different types of documents and 2 different types of ways that those documents can come. So, I´ve created this small widget to make it happen, that It worked great!
<?php
namespace App\Http\Controllers\API\Apps\Protocolos;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use Illuminate\Support\Facades\Storage;
class ObtenerProtocolos extends Controller
{
@akatche
akatche / 99fixbadproxy
Created December 6, 2019 13:33 — forked from trastle/99fixbadproxy
Fixing the issue with apt caused by a bad local proxy: -1- Create 99fixbadproxy at: /etc/apt/apt.conf.d/99fixbadproxy -2- Run clear.sh
Acquire::http::Pipeline-Depth "0";
Acquire::http::No-Cache=True;
Acquire::BrokenProxy=true;
@akatche
akatche / homestead-manual-install.md
Created March 3, 2020 11:59 — forked from idecardo/homestead-manual-install.md
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:

@akatche
akatche / createdb.sql
Last active October 7, 2022 13:08
Run Laravel parallel tests using Laravel Sail
#
# Create this file in the following folder docker/mysql/docker-entrypoint-initdb.d
#
CREATE DATABASE IF NOT EXISTS `test_1` COLLATE 'utf8_general_ci' ;
GRANT ALL ON `test_1`.* TO 'root'@'%' ;
CREATE DATABASE IF NOT EXISTS `test_2` COLLATE 'utf8_general_ci' ;
GRANT ALL ON `test_2`.* TO 'root'@'%' ;
@akatche
akatche / mysql-sail.md
Created July 5, 2022 14:26 — forked from jjcodes78/mysql-sail.md
Laravel Sail - GRANT ALL PRIVILEGES to user

Run this command in sail project folder:

docker-compose exec mysql bash

execute the mysql -u root -p command

provide the default password password

then executes