Skip to content

Commit

Permalink
CLEANUP comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Stewart committed Jun 21, 2012
1 parent eaa9813 commit 7556b49
Show file tree
Hide file tree
Showing 21 changed files with 114 additions and 98 deletions.
2 changes: 1 addition & 1 deletion contrib/install-hudson.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# ################################################################################ Hudson
#======================================| Hudson

# README:
#
Expand Down
2 changes: 1 addition & 1 deletion contrib/install-memcached.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# ################################################################################ memcached
#======================================| memcached

# README:
#
Expand Down
2 changes: 1 addition & 1 deletion contrib/install-pareview.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ CWD="$( cd -P "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source "${CWD}"/CONFIG
if [[ ${DEBUG} == true ]]; then set -x -v; fi

# ################################################################################ PAReview.sh
#======================================| PAReview.sh

# README:
#
Expand Down
2 changes: 1 addition & 1 deletion contrib/install-solr.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# ################################################################################ Apache SOLR - 183mb
#======================================| Apache SOLR - 183mb

# README:
#
Expand Down
2 changes: 1 addition & 1 deletion contrib/install-squid.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# ################################################################################ Squid caching of ftp.drupal.org
#======================================| Squid caching of ftp.drupal.org
# README:
#
# This script will install Squid for caching of ftp.drupal.org
Expand Down
27 changes: 19 additions & 8 deletions setup_scripts/1-prep.sh
Original file line number Diff line number Diff line change
@@ -1,18 +1,29 @@
#!/bin/bash
set -e
#======================================|
#
# THIS SCRIPT SETS UP ENVIRONMENT
#
# * Figure out environment
# * Update Zenity (due to bug in initial release of 12.04)
# * User: What Type of Install? (Abort / Virtual Kernel / Standard Kernel)
# * Setup: $USER in sudoers and root group
# * Add: wget, git, and curl -- which are used by installation scripts
#
#======================================|

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi


# ################################################################################ Update Zenity (12.04 from debian has a bug)
c Update Zenity (12.04 has a bug)
sudo apt-get install zenity

# ################################################################################
# Prompt to give user a chance to abort to avoid accidentally borking their system
# ################################################################################
################################################################################
# Prompt for installation type or to abort (to avoid borking system)
################################################################################
INSTALLTYPE=$(zenity \
--list \
--radiolist \
Expand Down Expand Up @@ -41,8 +52,8 @@ if [ "$UserAbort" -ne 0 ]; then # if cancel button(1), choose abort(3), or timeo
exit $UserAbort;
fi

# ok, lets do it
# SAVE INSTALLATION TYPE
#======================================| ok, lets do it
#======================================| SAVE INSTALLATION TYPE
echo "
# ################## START_USER_CONFIG
INSTALLTYPE=${INSTALLTYPE}" >> "${HOME}/${DDD}/setup_scripts/CONFIG"
Expand All @@ -56,7 +67,7 @@ Towards the end, the process requires some manual steps, guided by popups like t
echo "${USER} ALL=(ALL) NOPASSWD: ALL" | sudo tee -a "/etc/sudoers.d/${DDD}" > /dev/null
sudo chmod 440 "/etc/sudoers.d/${DDD}"

# ################################################################################ Install/Update some basics
#======================================| Install/Update some basics
sudo apt-get "${APTGET_VERBOSE}" install git wget curl

# Add current user to root 'group' to make it easier to edit config files
Expand Down
4 changes: 2 additions & 2 deletions setup_scripts/1a-vbox-guest-additions.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi

# ################################################################################ SETUP KERNEL
#======================================| SETUP KERNEL
if [ "${INSTALLTYPE}" == "virtual" ]
then
# Remove the standard Kernel and install virtual kernel.
Expand Down
2 changes: 1 addition & 1 deletion setup_scripts/2-slim.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi
Expand Down
2 changes: 1 addition & 1 deletion setup_scripts/2a-update.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi
Expand Down
16 changes: 8 additions & 8 deletions setup_scripts/3-lamp.sh
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi

# ################################################################################ Drupal sites
#======================================| Drupal sites
# Create folder for websites to live in
mkdir -p "${WWW_ROOT}"
sudo chown :www-data "${WWW_ROOT}"
sudo chmod -R u=rwX,g=rX,o= "${WWW_ROOT}"

# ################################################################################ Install LAMP packages
#======================================| Install LAMP packages
# Define package names, and debconf config values. Keep package names in sync.
LAMP_APACHE="libapache2-mod-php5 php-pear"
LAMP_MYSQL="mysql-server libmysqlclient18 mysql-common"
Expand Down Expand Up @@ -81,13 +81,13 @@ echo "<IfModule mod_ssl.c>
sudo a2ensite default-ssl


# ################################################################################ Configure MYSQL
#======================================| Configure MYSQL

sudo sed -i 's/#log_slow_queries/log_slow_queries/g' /etc/mysql/my.cnf
sudo sed -i 's/#long_query_time/long_query_time/g' /etc/mysql/my.cnf


# ################################################################################ Configure PHP
#======================================| Configure PHP
# FIXME haven't checked for unnecessary code since 9.10
# sudo sed -i 's/find_this/replace_with_this/g' infile1 infile2 etc
sudo sed -i 's/magic_quotes_gpc = On/magic_quotes_gpc = Off/g' /etc/php5/apache2/php.ini /etc/php5/cli/php.ini
Expand All @@ -112,7 +112,7 @@ echo "extension=uploadprogress.so" | sudo tee /etc/php5/apache2/conf.d/uploadpro



# ################################################################################ Log Files
#======================================| Log Files
mkdir -p "${LOGS}"


Expand All @@ -138,7 +138,7 @@ ln -s /var/log/mysql/mysql-slow.log "${LOGS}/mysql-slow.log



# ################################################################################ Config Files
#======================================| Config Files
mkdir -p "${CONFIGS}"
sudo chmod -R g+w /etc/apache2
ln -s /etc/apache2/apache2.conf "${CONFIGS}/apache2.conf"
Expand All @@ -163,7 +163,7 @@ ll
This will list the files and where they link to." > "${CONFIGS}/README.txt"

# ################################################################################ user management
#======================================| user management
# Make user of group www-data
sudo adduser $USER www-data

Expand Down
14 changes: 7 additions & 7 deletions setup_scripts/4-ides.sh
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi

# ################################################################################ JRE
#======================================| JRE
# REQUIREMENT for Netbeans or Eclipse
if [[ "${INSTALL_NETBEANS}" == true ]] || [[ "${INSTALL_ECLIPSE}" == true ]] || [[ "${INSTALL_JRE}" == true ]]; then
## Install java - 100mb
sudo apt-get "${APTGET_VERBOSE}" install default-jre
fi

# ################################################################################ Lightweight Editors
# ################################################################################ GEDIT
#======================================| Lightweight Editors
#======================================| GEDIT
if [[ "${INSTALL_GEDIT}" == true ]]; then
sudo apt-get "${APTGET_VERBOSE}" install gedit-plugins

Expand All @@ -30,7 +30,7 @@ if [[ "${INSTALL_GEDIT}" == true ]]; then
gconftool-2 -s /apps/gedit-2/preferences/editor/save/auto_save --type=bool true
fi

# ################################################################################ GEANY
#======================================| GEANY
# INSTALL GEANY & SETUP FOR DRUPAL / WEB DEVELOPMENT
# Geany is a small fast IDE (based on scintilla ... also what notepad++ is also built on)
# info: http://en.wikipedia.org/wiki/Geany
Expand All @@ -52,7 +52,7 @@ if [[ "${INSTALL_GEANY}" == true ]]; then
wget "${WGET_VERBOSE}" -O ${HOME}/.config/geany/tags/geany-tags-css --referer="${REFERER}" --user-agent="${USERAGENT}" --header="${HEAD1}" --header="${HEAD2}" --header="${HEAD3}" --header="${HEAD4}" --header="${HEAD5}" "${GEANY_CSS}"
fi

# ################################################################################ ECLIPSE
#======================================| ECLIPSE
if [[ "${INSTALL_ECLIPSE}" == true ]]; then
wget "${WGET_VERBOSE}" -O eclipse.tar.gz --referer="${REFERER}" --user-agent="${USERAGENT}" --header="${HEAD1}" --header="${HEAD2}" --header="${HEAD3}" --header="${HEAD4}" --header="${HEAD5}" "${ECLIPSE_URL}"
cd
Expand All @@ -65,7 +65,7 @@ if [[ "${INSTALL_ECLIPSE}" == true ]]; then
sudo cp ${HOME}/eclipse-php/configuration/org.eclipse.osgi/bundles/224/1/.cp/icons/eclipse48.png /usr/share/pixmaps/eclipse.png
fi

# ################################################################################ NETBEANS
#======================================| NETBEANS
if [[ "${INSTALL_NETBEANS}" == true ]]; then
cd
wget "${WGET_VERBOSE}" -O netbeans.sh --referer="${REFERER}" --user-agent="${USERAGENT}" --header="${HEAD1}" --header="${HEAD2}" --header="${HEAD3}" --header="${HEAD4}" --header="${HEAD5}" "${NETBEANS_URL}"
Expand Down
8 changes: 4 additions & 4 deletions setup_scripts/7-config.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi
Expand Down Expand Up @@ -40,20 +40,20 @@ APT::Periodic::Unattended-Upgrade \"1\";
" | sudo tee /etc/apt/apt.conf.d/10periodic > /dev/null


# ################################################################################ Replace localhost/index.html
#======================================| Replace localhost/index.html
# Add interesting default document for localhost
sudo rm /var/www/index.html
sudo cp ${HOME}/${DDD}/config/index.php /var/www/index.php
sudo chmod -R u=rwX,g=rX,o= /var/www
sudo chown -R $USER:www-data /var/www

# ################################################################################ Command line shortcuts (bash aliases)
#======================================| Command line shortcuts (bash aliases)

# Don't sudo here...
cat ${HOME}/${DDD}/config/ddd_bash_aliases >> ${HOME}/.bash_aliases


# ################################################################################ Desktop shortcuts
#======================================| Desktop shortcuts

cat > ${HOME}/Desktop/README.desktop <<END
#!/usr/bin/env xdg-open
Expand Down
2 changes: 1 addition & 1 deletion setup_scripts/8-manualconfig.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
set -e

# ################################################################################ Import Variables
#======================================| Import Variables
# Make sure you have edited this file
source "${HOME}/${DDD}/setup_scripts/CONFIG"
if [[ ${DEBUG} == true ]]; then set -x -v; fi
Expand Down
Loading

0 comments on commit 7556b49

Please sign in to comment.