Friday, April 12, 2013

Installing elgg onto Amazon EC2 server instance

Log into your AWS instance. This is covered in previous articles.

Edit the httpd.conf file

sudo vi /etc/httpd/conf/httpd.conf

What I looked for here is not the first <Directory> directive, but the second one, that begins:

<Directory "/var/www/html">

The first one is a default section to remove all default rights from everythings. The second one grants back the rights we want to the document pointed to by the path.

Inside this section change:

AllowOverride None

To:

AllowOverride All

This allows us to then put a .htaccess file into /var/www/html/ during the next step to control rewriting for the web server.

Enter the following to prevent an error and satisfy dependencies for the install:

sudo yum install php-xml
sudo yum install php-gd
sudo yum install php-mysql
sudo yum install php-mbstring

Restart your web server:

sudo /etc/init.d/httpd restart




 

Installing and configuring Elgg:

Use wget to download the Elgg tar ball.

wget http://path to the download

that you can see by hovering over the link on the elgg download page. Right click and copy link to put the url into your paste butter.

unzip this and copy the contents of the zip directory into /var/www/http


Change permissions and create a data directory



cd /var/www/http

sudo mkdir data

sudo chown -R apache:apache .

sudo mv data ..

sudo cp htaccess_dist .htaccess


Create the database:

mysql -u root -p
CREATE DATABASE elgg;
CREATE USER elgguser IDENTIFIED BY 'elgguserpassword';
GRANT ALL ON elgg.* to elgguser;

Of course you should change at least the password to something secure.
Run the elgg install script 

In your browser go to:
http://yourhostname/

And it automatically brings up the installer.

Follow the prompts.

The database stuff is what you entered when you created the table just above this.

The data directory is /var/www/data

After the install, rename the install.php file so that it can no longer be accessed by placing a large number of random characters after the user name.

Wednesday, April 10, 2013

The virtues and leading a good life.

The ancient Greeks believed that there were virtues, or habits, that one could learn that would lead, if fate allowed, to a happier life

It was recognized that we humans are a mass of swarming desires, and that  trying to control all these desires, each wanting to go in its own direction, was a lot like herding cats.  Each of these desires seemed to have two contradictory extremes, going too far in one direction or the other. They saw the attempt to totally eliminate a desire as bad for someone as if they gave in totally to that desire.  As if a desire were a wolf that you were starving, eventually it will break free and be totally out of control until it is satiated.   It was noted that people who allow their desires to lead them to one extreme or the other are the most miserable people alive, and appear to have no control over what happens in their lives.

A virtue is the habit of seeking a balance between two extremes of a desire, such as hunger balanced between starvation and gluttony, or love balanced between madness and the total lack thereof, the desire to drink and go to parties should balance between being out of control and staying in every night.  Given anything with two extremes one should always seek the middle path, one should seek balance.  Moderation in all things, abstinence only in those things that would instantly poison your reason or your body.

The Greeks saw that we should seek balance among all the virtues, our job should balance perfectly against  family obligations,  finances balanced against the desire for more stuff, and so on.  By consistently choosing the middle path using the rational mind, not starving or overfeeding any one desire at the expense of all the others, we would build up the habits that would lead to success in every area of  life and allow us to seek fulfilment.  Over time our desires will become used to the caring concern that your rational mind tends to them all, and fall into line, not raging to be in control all the time, and not withered away and starving.