Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
//Vagrant
//Ubuntu 14.04
//Requirement: install mongodb in the vagrant
sudo docker pull mongoclient/mongoclient
//Refer to http://dockone.io/article/152
sudo docker run -d -p 3000:3000 --net=host -v ~/mongoclient:/data/db --name mongoclient mongoclient/mongoclient
@dickstar
dickstar / vagrant_fix.sh
Last active March 14, 2017 04:09
Solve Vagrant error : Failed to mount folders in Linux guest
# Vagrant was unable to mount VirtualBox shared folders. This is usually
# because the filesystem "vboxsf" is not available. This filesystem is
# made available via the VirtualBox Guest Additions and kernel module.
# Please verify that these guest additions are properly installed in the
# guest. This is not a bug in Vagrant and is usually caused by a faulty
# Vagrant box. For context, the command attempted was:
# mount -t vboxsf -o uid=1000,gid=1000 vagrant /vagrant
# The error output from the command was:
@dickstar
dickstar / install_pcel_mongodb.sh
Last active March 8, 2017 12:37
For php7.0 in ubuntu 14.04
#!/bin/bash
sudo apt-get install php-pear
sudo pecl channel-update pecl.php.net
sudo apt-get install -y php7.0-dev
sudo apt-get install pkg-config libssl-dev
sudo pecl install mongodb
// add extension=mongodb.so to /etc/php/7.0/fpm/php.ini
//Enviroment
//ubuntu 14.04
//wordpress 4.7.3
//CiviCRM 4.7.16
Download wordpress, https://tw.wordpress.org/releases/
extract to web
create database wordpress
access to http://localhost/wordpress
//Follow https://laravel.com/docs/5.4/dusk
//original dusk is used for graphic
//for vagrant, we have to open a terminal window
//composer require laravel/dusk
//Register provider
//php artisan dusk:install
sudo apt-get update
#!/bin/bash
mkdir ~/gulp
cd ~/gulp
sudo npm install gulp-cli -g
npm install gulp -D
touch gulpfile.js
#!/bin/bash
//vagrant
//ubuntu 14.04
composer global require "laravel/installer"
echo "export PATH=~/.config/composer/vendor/bin/:$PATH" >> ~/.bashrc
@dickstar
dickstar / install_mysql.sh
Created January 12, 2017 13:24
[One Click Install] Install mysql on Ubuntu 14.04
#!/bin/bash
sudo apt-get install -y mysql-server mysql-client libmysqlclient-dev
mysql -u root -pPassword