Skip to content

Instantly share code, notes, and snippets.

View niccolox's full-sized avatar
🍀
lucky

Nicholas Roberts niccolox

🍀
lucky
View GitHub Profile
@niccolox
niccolox / cartodb20_build.sh
Last active December 19, 2015 00:49 — forked from ericmagnuson/cartodb20_build.sh
hackish script for cartodb2 on precise
cd cartodb20
git checkout master
git submodule update
git submodule foreach git checkout master
sudo aptitude install -y unp
# Install GDAL, GEOS, PROJ, JSON-C, and PostGIS
echo 'yes' | sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable
sudo apt-get update
sudo apt-get install -y libgdal-dev libgeos-dev libproj-dev gdal-bin postgis postgresql-plpython-9.1 libjson0 libjson0-dev python-gdal
@niccolox
niccolox / precise-desktop-tweaks.sh
Last active December 28, 2015 22:19
precise devops ux misc script
sudo apt-get update && apt-get upgrade -y
sudo apt-get install python-software-properties
sudo add-apt-repository -y ppa:webupd8team/themes
sudo apt-get update
sudo apt-get install mediterraneannight-gtk-theme
sudo add-apt-repository -y ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer -y
sudo add-apt-repository -y ppa:tualatrix/ppa
sudo apt-get update
## WARNING - this one needs some major love
sudo apt-get --purge remove byobu
sudo apt-get install openssh-server openssh-client
sudo apt-get install python-software-properties
sudo apt-get install apt-show-versions
sudo apt-get -f install
sudo apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl apt-show-versions python
wget http://prdownloads.sourceforge.net/webadmin/webmin_1.660_all.deb
sudo dpkg --install webmin_1.660_all.deb
cd ~/Downloads
@niccolox
niccolox / boa213-drupal.sh
Last active December 30, 2015 15:09
A simple rsync bash script that sucks down platforms from the excellent Aegir BOA open hosting platform into a Drupalpro shared folder for easy development
#!/bin/bash
# to dos
# 1. remove existing sites from existing platforms
# i.e. works best on a clean install
# 2. generalize for regex of platforms?
# 3 all platforms?
echo "Aegir BOA 213 to Drupalpro Shared Folder"
echo "This is where it starts"
@niccolox
niccolox / qc-install-drupalpro-boa213.sh
Last active December 30, 2015 15:59
Installs sites on Drupalpro using Aegir BOA 213 platforms
# Drupal Commerce Kickstart
echo "Drupal Commerce Kickstart: commerce-7.x-2.9-7.23.3"
sudo mkdir /home/drupalpro/websites/commerce.dev
sudo cp -far /home/drupalpro/Desktop/shared/boa213platforms/commerce/commerce-7.x-2.9-7.23.3 /home/drupalpro/websites/
sudo mv /home/drupalpro/websites/commerce-7.x-2.9-7.23.3 /home/drupalpro/websites/commerce.dev
sudo cp /home/drupalpro/websites/commerce.dev/sites/default/default.settings.php /home/drupalpro/websites/commerce.dev/sites/default/settings.php
sudo mkdir /home/drupalpro/websites/commerce.dev/sites/default/files
sudo chown -R drupalpro:www-data /home/drupalpro/websites/commerce.dev
sudo chmod -R 755 /home/drupalpro/websites/commerce.dev
drush qc install --domain=commerce.dev dns apache database --codepath=/home/drupalpro/websites/commerce.dev --profile=commerce_kickstart
@niccolox
niccolox / mean.sh
Last active December 30, 2015 16:09
Ubuntu 12 install of MEAN from Linnovate
148 user@mean:~/mean⟫ history | cut -c 8-
cd ~/scripts
sudo chmod +x precise-desktop-tweaks.sh
sudo ./precise-desktop-tweaks.sh
mkdir ~/scripts
cd scripts
ls -alh
sudo nano /etc/hosts
sudo nano /etc/hostname
hostname -a
@niccolox
niccolox / nutch-clean.sh
Created December 10, 2013 19:29
clean nutch solr hdfs temp for www.BigDataDrupal.org
# nutch hdfs clean
echo "clean nutch solr hdfs temp"
#!/bin/bash
sudo -u hdfs hadoop fs -rm -R -skipTrash /user/pseudo/nutch/crawls
sudo -u hdfs hadoop fs -rm -R -skipTrash /user/hdfs/generate*
sudo -u hdfs hadoop fs -rm -R -skipTrash /user/hdfs/inject*
sudo -u hdfs hadoop fs -rm -R -skipTrash /user/hdfs/link*
sudo -u hdfs hadoop fs -rm -R -skipTrash /user/hdfs/tmp*
sudo -u hdfs hadoop fs -rm -R -skipTrash /user/hdfs/.staging/job*
curl http://searcher.server.ltd:8088/solr/somesolr/update?stream.body=%3Cdelete%3E%3Cquery%3E*:*%3C/query%3E%3C/delete%3E
@niccolox
niccolox / drupalpro-openenterprise.txt
Last active December 31, 2015 18:39
Open Enterprise 7.x 3.x NOTE: too many bugs, and Omega 3, so stopped using this before dev really began
## openenterprise.make
##
; To generate with Drush make, copy this file to e.g. stub.make
; and enter in your shell / command line:
; drush make --prepare-install stub.make folder_of_your_site
core = 7.x
api = 2
@niccolox
niccolox / gist:8294579
Last active January 2, 2016 11:09
warts and all deis install on precise NOTE there is an error in documentation around the berks install and I got confused about paths etc based on 3 docs http://docs.deis.io/en/latest/contributing/localdev/ http://docs.deis.io/en/v0.2.1/installation/vagrant/ https://github.com/opdemand/deis/tree/master/contrib/vagrant and one messy issue https:/…
# deis install
clear
sudo apt-get remove --purge openssh-server avahi-daemon
sudo mv /var/run/avahi-daemon /var/run/avahi-daemon_bak
sudo apt-get remove --purge openssh-server avahi-daemon
clear
sudo apt-get install fail2ban python-software-properties curl apt-transport-https -y
sudo reboot now
cd /home/niccolox/Projects/deis/deisvagrant
cd deis
@niccolox
niccolox / Vagrantfile
Last active August 29, 2015 13:56
Devshop Vagrantfile - use install.vagrant.sh to run this ... "./install.vagrant.sh" do not use sudo, use regular Vagrant user
# -*- mode: ruby -*-
# vi: set ft=ruby :
$devshop_hosts = <<SCRIPT
#!/bin/bash
cat > /etc/hosts <<EOF
127.0.0.1 localhost
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback