UASDrupal: Difference between revisions

From Unallocated Space
Jump to navigation Jump to search
(UASDrupal Project, first draft)
 
 
(30 intermediate revisions by one other user not shown)
Line 1: Line 1:
= UASDrupal Project =
= [http://uas.hepnermedia.com/ UAS Web Site 1.0 -- TRY ME!] =
= [https://github.com/Unallocated/UASDrupal UASDrupal Project] =
== Development Server Setup ==
== Development Server Setup ==
<span style="font-size:x-small;">Revised Mar 22, 2014 aj</>
<span style="font-size:x-small;">Revised Mar 26, 2014 aj
=== Platform Setup ===
=== Platform Setup ===
* Physical Machine
* Physical Machine
Line 44: Line 45:
   Copyright (c) 1997-2012 The PHP Group
   Copyright (c) 1997-2012 The PHP Group
   Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
   Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
* XFCE4 Screenshooter Plugin
sudo apt-get install xfce4-screenshooter-plugin
=== Development Software Setup ===
=== Development Software Setup ===
==== [http://www.git-scm.org GIT] ====
==== [http://www.git-scm.org GIT] ====
Line 66: Line 70:
* Download <i>LibreOffice 4.2.2 for Linux x64 (deb)</i> using the LibreOffice website download button or link.  Also download the Help Pack.
* Download <i>LibreOffice 4.2.2 for Linux x64 (deb)</i> using the LibreOffice website download button or link.  Also download the Help Pack.
  $ tar xzvf LibreOffice_4.2.2_Linux_x86-64_deb.tar.gz
  $ tar xzvf LibreOffice_4.2.2_Linux_x86-64_deb.tar.gz
  $ cd LibreOffice_4.2.2.1_Linux_x86-64_deb
  $ cd LibreOffice_4.2.2.1_Linux_x86-64_deb/DEBS
/DEBS
  $ sudo dpkg -i *.deb
  $ sudo dpkg -i *.deb
  $ tar xzvf LibreOffice_4.2.2_Linux_x86-64_deb_helppack_en-US
  $ tar xzvf LibreOffice_4.2.2_Linux_x86-64_deb_helppack_en-US.tar.gz
.tar.gz
  $ cd LibreOffice_4.2.2.1_Linux_x86-64_deb_helppack_en-US/DEBS
  $ cd LibreOffice_4.2.2.1_Linux_x86-64_deb_helppack_en-US/DEBS
  $ sudo dpkg -i *.deb
  $ sudo dpkg -i *.deb
== Utility Software Setup ==
=== Install Curl ===
* Curl is utility for downloading files
$ sudo apt-get install curl
=== Install Composer ===
* Composer is a Drush dependency
<pre>
$ curl -sS https://getcomposer.org/installer | php
$ sudo mv composer.phar /usr/local/bin/composer
$ compose
  ______
  / ____/___  ____ ___  ____  ____  ________  _____
/ /  / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/
/ /___/ /_/ / / / / / / /_/ / /_/ (__  )  __/ /
\____/\____/_/ /_/ /_/ .___/\____/____/\___/_/
                    /_/
Composer version 45fe0124f2dae5ee66da389c82c70323e28f36d6 2014-03-24 10:51:54
</pre>
=== Drush Install ===
<pre>
$ cd /opt
$ git clone https://github.com/drush-ops/drush.git drush.g
$ cd drush.g
$ compose global require drush/drush:dev-master
Changed current directory to /home/ajs/.composer
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
  - Installing pear/console_table (1.1.5)
    Downloading: 100%       
  - Installing symfony/yaml (v2.2.1)
    Downloading: 100%       
  - Installing d11wtq/boris (v1.0.8)
    Downloading: 100%       
  - Installing drush/drush (dev-master 2083272)
    Cloning 2083272379a4c981f70f137af6928c7c1a092f8c
pear/console_table suggests installing pear/Console_Color (>=0.0.4)
drush/drush suggests installing youngj/httpserver (dev-master#41dd2b7 as 1.0.1)
Writing lock file
Generating autoload files
</pre>
= Drupal Setup =
== Project Collaboration Setup ==
== Project Collaboration Setup ==
* Login to GitHub and navigate to the [https://github.com/Unallocated/UASDrupal UASDrupal Project]
* Login to GitHub and navigate to the [https://github.com/Unallocated/UASDrupal UASDrupal Project]
* Click the <b>Fork</b> button.  This will create a GitHub clone of the project in your account and switch to your clone of the project.
* Click the <b>Fork</b> button.  This will create a GitHub clone of the project in your account and switch to your clone of the project.
* Copy the <i>HTTPS clone URL</i> to your clipboard and use it to clone the project to the development server.
* Copy the <i>HTTPS clone URL</i> to your clipboard and use it to clone the project to the development server.
  $ git clone https://github.com/you/UASDrupal.git UASDrupal
* clone the forked git UASDrupal repository to the web server's default root /var/www
  $ cd /var/www
$ sudo git clone https://github.com/you/UASDrupal.git UASDrupal
   Cloning into 'UASDrupal.f'...
   Cloning into 'UASDrupal.f'...
   remote: Reusing existing pack: 14608, done.
   remote: Reusing existing pack: 14608, done.
Line 84: Line 137:
   Resolving deltas: 100% (5655/5655), done.
   Resolving deltas: 100% (5655/5655), done.
   Checking connectivity... done.
   Checking connectivity... done.
=== Apache2 Configuration ===
* sudo vi /etc/apache2/sites-available/default
<pre>
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/UASDrupal/docroot
<Directory />
  Options FollowSymLinks
  AllowOverride None
</Directory>
<Directory /var/www/UASDrupal/docroot>
  Options Indexes FollowSymLinks MultiViews
  AllowOverride All
  Order allow,deny
  allow from all
</Directory>
* * * no changes to remaining content * * *
</pre>
=== PHP Configuration ===
==== PHP gd Extensions ====
$ sudo apt-get install php-gd
$ sudo service apache2 restart
==== php.ini ====
* sudo vi /etc/php5/apache2/php.ini 
<pre>
upload_max_filesize = 200M
post_max_size = 200M
memory_limit = 1024M
max_execution_time = 120
</pre>
* Do the same settings update if php client is installed: sudo vi /etc/php5/cli/php.ini
Note: I notice that the initial <b>memory_limit = -1</b> in the /etc/php5/cli/php.ini
== Database Setup ==
<pre>
$ mysqladmin -u root -p create uasdrupal
$ mysql -u root -p
mysql> GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES ON usadrupal.* TO 'root'@'localhost' IDENTIFIED BY 'unPassword';
mysql> exit
</pre>
== memcache setup ==
* [http://andrewdunkle.com/how-install-memcached-drupal-7 Ref: How to Install Memcached for Drupal 7 - AndrewDunkle.com]
<pre>
$ sudo apt-get install memcached libmemcached-tools
$ sudo apt-get install php5-dev php-pear make
$ sudo pecl install memcache
$ sudo nano /etc/php5/conf.d/memcache.ini
    extension=memcache.so
    memcache.hash_strategy="consistent"
$ sudo nano /etc/memcached.conf
    -m 64
$ sudo /etc/init.d/memcached restart
$ sudo /etc/init.d/apache2 restart
# Test
$ sudo netstat -tap | grep memcached
</pre>
== Drupal Runtime Configuration ==
* Navigate local browser to http://localhost and select <b>Unallocated - Build profile for Unallocated Space (http://unallocatedspace.org)</b>
== Security ==
$ chmod 644 sites/default/settings.php
= It Works!  I Think! =
[[File:UASDrupal Dev 01.png]]
[[Category:Project]]

Latest revision as of 20:42, 5 January 2023

UAS Web Site 1.0 -- TRY ME!

UASDrupal Project

Development Server Setup

Revised Mar 26, 2014 aj

Platform Setup

  • Physical Machine

Alienware M15x, i7, 8core, 8GB RAM, 700GB HD, 1920x1050 Video, Wired Ethernet (DHCP)

  • Virtual Machine (VirtualBox 4.3.8)

Ubuntu Linux/64, 3 CPU, 3072GB RAM, 128MB Video RAM, 256GB VHD (dynamic)
Bridged Ethernet (DHCP for initial setup)

Operating System Setup

Install from mini.iso
In the Package Configuration, Software Selection select the following:
 * Basic Ubuntu Server
 * OpenSSH
Assure Time Zone is correct.  If prompted for UTC Hardware Clock, select NO.
Reboot
  • Ubuntu Setup Continued... Terminal commands are preceded with the Linux prompt $ below.
$ sudo apt-get update
$ sudo tasksel
In the Package Configuration, Software Selection select the following:
 * Basic Ubuntu Server
 * OpenSSH
 * Xubuntu desktop
$ sudo reboot
  • Ubuntu Setup Continued...
$ sudo tasksel
In the Package Configuration, Software Selection select the following:
 * Basic Ubuntu Server
 * OpenSSH
 * LAMP server
 * Xubuntu desktop
  • The basic Ubuntu development server is now setup. Test it:
$ apache2 -v
  Server version: Apache/2.2.22 (Ubuntu)
  Server built:   Jul 12 2013 13:37:10
$ mysql
  Welcome to the MySQL monitor.  Commands end with ; or \g.
  Your MySQL connection id is 42
  Server version: 5.5.35-0ubuntu0.12.04.2 (Ubuntu)
$ php -v
  PHP 5.3.10-1ubuntu3.10 with Suhosin-Patch (cli) (built: Feb 28 2014 23:14:25) 
  Copyright (c) 1997-2012 The PHP Group
  Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
  • XFCE4 Screenshooter Plugin
sudo apt-get install xfce4-screenshooter-plugin

Development Software Setup

GIT

  • Install GIT dependencies
sudo apt-get install -y libcurl4-openssl-dev libexpat1-dev gettext libz-dev libssl-dev build-essential
  • Build GIT from Source Code
Download the git source code from:  git-1.9.1.zip
Extract the zip file to /home/you/Donwloads/git-1.9.1
$ cd /home/you/Donwloads/git-1.9.1
$ make prefix=/usr/local all
$ sudo make prefix=/usr/local install
$ sudo adduser --disabled-login git
  • Test git:
$ git --version
  git version 1.9.1

Evolus Pencil

  • Design Software to work with files like the UASDrupal Project / Boiler Plate Wireframe - Pencil template header-footer-template.ep
Download the Pencil deb
$ sudo dpkg -i evoluspencil_2.0.5_all.deb

LibreOffice

  • Use the Synaptic Package Manager to uninstall the Ubuntu default LibreOffice 3
  • Download LibreOffice 4.2.2 for Linux x64 (deb) using the LibreOffice website download button or link. Also download the Help Pack.
$ tar xzvf LibreOffice_4.2.2_Linux_x86-64_deb.tar.gz
$ cd LibreOffice_4.2.2.1_Linux_x86-64_deb/DEBS
$ sudo dpkg -i *.deb
$ tar xzvf LibreOffice_4.2.2_Linux_x86-64_deb_helppack_en-US.tar.gz
$ cd LibreOffice_4.2.2.1_Linux_x86-64_deb_helppack_en-US/DEBS
$ sudo dpkg -i *.deb

Utility Software Setup

Install Curl

  • Curl is utility for downloading files
$ sudo apt-get install curl

Install Composer

  • Composer is a Drush dependency
 $ curl -sS https://getcomposer.org/installer | php
 $ sudo mv composer.phar /usr/local/bin/composer
 $ compose
   ______
  / ____/___  ____ ___  ____  ____  ________  _____
 / /   / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/
/ /___/ /_/ / / / / / / /_/ / /_/ (__  )  __/ /
\____/\____/_/ /_/ /_/ .___/\____/____/\___/_/
                    /_/
Composer version 45fe0124f2dae5ee66da389c82c70323e28f36d6 2014-03-24 10:51:54

Drush Install

$ cd /opt
$ git clone https://github.com/drush-ops/drush.git drush.g
$ cd drush.g
$ compose global require drush/drush:dev-master
 Changed current directory to /home/ajs/.composer
 ./composer.json has been updated
 Loading composer repositories with package information
 Updating dependencies (including require-dev)
   - Installing pear/console_table (1.1.5)
     Downloading: 100%         

   - Installing symfony/yaml (v2.2.1)
     Downloading: 100%         

   - Installing d11wtq/boris (v1.0.8)
     Downloading: 100%         

   - Installing drush/drush (dev-master 2083272)
     Cloning 2083272379a4c981f70f137af6928c7c1a092f8c

 pear/console_table suggests installing pear/Console_Color (>=0.0.4)
 drush/drush suggests installing youngj/httpserver (dev-master#41dd2b7 as 1.0.1)
 Writing lock file
 Generating autoload files

Drupal Setup

Project Collaboration Setup

  • Login to GitHub and navigate to the UASDrupal Project
  • Click the Fork button. This will create a GitHub clone of the project in your account and switch to your clone of the project.
  • Copy the HTTPS clone URL to your clipboard and use it to clone the project to the development server.
  • clone the forked git UASDrupal repository to the web server's default root /var/www
$ cd /var/www
$ sudo git clone https://github.com/you/UASDrupal.git UASDrupal
  Cloning into 'UASDrupal.f'...
  remote: Reusing existing pack: 14608, done.
  remote: Total 14608 (delta 0), reused 0 (delta 0)
  Receiving objects: 100% (14608/14608), 24.03 MiB | 305.00 KiB/s, done.
  Resolving deltas: 100% (5655/5655), done.
  Checking connectivity... done.

Apache2 Configuration

  • sudo vi /etc/apache2/sites-available/default
<VirtualHost *:80>
 ServerAdmin webmaster@localhost

 DocumentRoot /var/www/UASDrupal/docroot
 <Directory />
   Options FollowSymLinks
   AllowOverride None
 </Directory>
 <Directory /var/www/UASDrupal/docroot>
   Options Indexes FollowSymLinks MultiViews
   AllowOverride All
   Order allow,deny
   allow from all
 </Directory>

 * * * no changes to remaining content * * *

PHP Configuration

PHP gd Extensions

$ sudo apt-get install php-gd
$ sudo service apache2 restart

php.ini

  • sudo vi /etc/php5/apache2/php.ini
 upload_max_filesize = 200M
 post_max_size = 200M
 memory_limit = 1024M
 max_execution_time = 120
  • Do the same settings update if php client is installed: sudo vi /etc/php5/cli/php.ini

Note: I notice that the initial memory_limit = -1 in the /etc/php5/cli/php.ini

Database Setup

$ mysqladmin -u root -p create uasdrupal
$ mysql -u root -p
mysql> GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES ON usadrupal.* TO 'root'@'localhost' IDENTIFIED BY 'unPassword';
mysql> exit

memcache setup

$ sudo apt-get install memcached libmemcached-tools
$ sudo apt-get install php5-dev php-pear make
$ sudo pecl install memcache
$ sudo nano /etc/php5/conf.d/memcache.ini
    extension=memcache.so
    memcache.hash_strategy="consistent"
$ sudo nano /etc/memcached.conf
    -m 64
$ sudo /etc/init.d/memcached restart
$ sudo /etc/init.d/apache2 restart
# Test
$ sudo netstat -tap | grep memcached

Drupal Runtime Configuration

Security

$ chmod 644 sites/default/settings.php

It Works! I Think!