<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://mars.merhot.dk/w/index.php?action=history&amp;feed=atom&amp;title=Webserver_with_CMS</id>
		<title>Webserver with CMS - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://mars.merhot.dk/w/index.php?action=history&amp;feed=atom&amp;title=Webserver_with_CMS"/>
		<link rel="alternate" type="text/html" href="http://mars.merhot.dk/w/index.php?title=Webserver_with_CMS&amp;action=history"/>
		<updated>2026-05-08T05:52:54Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.29.0</generator>

	<entry>
		<id>http://mars.merhot.dk/w/index.php?title=Webserver_with_CMS&amp;diff=22448&amp;oldid=prev</id>
		<title>Okdios: Created page with &quot;'''Ubuntu:''' The first thing we did, was to install Ubuntu. We used the new LTS version, 12.04.    '''Apache (LAMP):''' Next thing was to install Apache, MySQL and PHP. We used ...&quot;</title>
		<link rel="alternate" type="text/html" href="http://mars.merhot.dk/w/index.php?title=Webserver_with_CMS&amp;diff=22448&amp;oldid=prev"/>
				<updated>2012-05-03T09:52:58Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;&amp;#039;&amp;#039;&amp;#039;Ubuntu:&amp;#039;&amp;#039;&amp;#039; The first thing we did, was to install Ubuntu. We used the new LTS version, 12.04.    &amp;#039;&amp;#039;&amp;#039;Apache (LAMP):&amp;#039;&amp;#039;&amp;#039; Next thing was to install Apache, MySQL and PHP. We used ...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;'''Ubuntu:'''&lt;br /&gt;
The first thing we did, was to install Ubuntu. We used the new LTS version, 12.04.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Apache (LAMP):'''&lt;br /&gt;
Next thing was to install Apache, MySQL and PHP. We used the easy way, by selecting the LAMP stack during installation of Ubuntu.&lt;br /&gt;
If you forget to select it during installation, simply type 'tasksel' in a shell, and you get the same menu where you can select LAMP.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''SSL:'''&lt;br /&gt;
We have set up our server to be apple to work with encrypted traffic. To do this we had to enable SSL.&lt;br /&gt;
Commands to do this:&lt;br /&gt;
generate keys for CSR (Certificate Signing Request)&lt;br /&gt;
* openssl genrsa -des3 -out server.key 1024&lt;br /&gt;
Create insecure key&lt;br /&gt;
* openssl rsa -in server.key -out server.key.insecure&lt;br /&gt;
* mv server.key server.key.secure&lt;br /&gt;
* mv server.key.insecure server.key&lt;br /&gt;
Create the CSR&lt;br /&gt;
* openssl req -new -key server.key -out server.csr&lt;br /&gt;
Sign the certificate&lt;br /&gt;
* openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt&lt;br /&gt;
Copy the files to the right dirs&lt;br /&gt;
* cp server.crt /etc/ssl/certs&lt;br /&gt;
* cp server.key /etc/ssl/private&lt;br /&gt;
Enable SSL&lt;br /&gt;
* a2enmod ssl&lt;br /&gt;
enable certifikate file&lt;br /&gt;
* a2ensite &amp;quot;filename&amp;quot;&lt;br /&gt;
disable certifikate file&lt;br /&gt;
* a2dissite &amp;quot;filename&amp;quot;&lt;br /&gt;
Reload apache server&lt;br /&gt;
* service apache2 reload&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Tomcat:'''&lt;br /&gt;
To install Tomcat, we first had to make sure Java was installed:&lt;br /&gt;
* apt-get install openjdk-7-jre&lt;br /&gt;
&lt;br /&gt;
Then we could install Tomcat, with these commands (including documentation):&lt;br /&gt;
* mkdir Tomcat&lt;br /&gt;
* wget http://apache.hoxt.com/tomcat/tomcat-7/v7.0.27/bin/apache-tomcat-7.0.27-fulldocs.tar.gz&lt;br /&gt;
* tar -zxvf apache-tomcat-7.0.27-fulldocs.tar.gz&lt;br /&gt;
* wget http://apache.hoxt.com/tomcat/tomcat-7/v7.0.27/bin/apache-tomcat-7.0.27.tar.gz&lt;br /&gt;
* tar -zxvf apache-tomcat-7.0.27.tar.gz&lt;br /&gt;
* cd apache-tomcat-7.0.27/bin&lt;br /&gt;
* ./startup.sh&lt;br /&gt;
'''Drupal (CMS):'''&lt;br /&gt;
We read about different CMS', and we agreed that Drupal seemed to be the best choice for us. &lt;br /&gt;
* It s very easy to install.&lt;br /&gt;
* The administrator panel is quite easy to navigate in.&lt;br /&gt;
* It is easy to create new content.&lt;br /&gt;
* There are themes/plugins for every need.&lt;br /&gt;
* It is possible to include php and javascript code directly in your page content.&lt;br /&gt;
&lt;br /&gt;
The installation was done in a few easy steps.&lt;br /&gt;
# Download and extract latest version of Drupal from their website.&lt;br /&gt;
# Create a database.&lt;br /&gt;
# Point a browser to your server, and follow instructions.&lt;br /&gt;
That's it!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''NOAA Weather information:'''&lt;br /&gt;
We have created a script, which we run hourly on the server. The script fetches a textfile with weather information&lt;br /&gt;
from Karup. The information from this textfile is parsed, and formatted to be easier to read (This is done with a small php script).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''DNS:'''&lt;br /&gt;
To setup our server to act as a DNS server, we installed bind9 (apt-get install bind9).&lt;br /&gt;
To configure it, we needed to change some configuration files to look like this:&lt;br /&gt;
/etc/bind/named.conf.local looks like this:&lt;br /&gt;
&amp;lt;source lang=cli&amp;gt;&lt;br /&gt;
# Our domain zone&lt;br /&gt;
zone &amp;quot;mo-web.local&amp;quot;&lt;br /&gt;
{&lt;br /&gt;
    type master;&lt;br /&gt;
    file &amp;quot;/etc/bind/zones/mo-web.local.db&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
# For reverse DNS&lt;br /&gt;
zone &amp;quot;0.0.10.in-addr-arpa&amp;quot;&lt;br /&gt;
{&lt;br /&gt;
    type master;&lt;br /&gt;
    file &amp;quot;/etc/bind/zones/rev.0.0.10.in-addr.arpa&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
in /etc/bind/named.conf.options, uncomment this section, and add some DNS servers:&lt;br /&gt;
&amp;lt;source lang=cli&amp;gt;&lt;br /&gt;
forwarders {&lt;br /&gt;
		8.8.8.8;&lt;br /&gt;
                8.8.4.4;&lt;br /&gt;
                0.0.0.0;&lt;br /&gt;
	};&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
/etc/bind/zones/mo-web.local.db looks like this:&lt;br /&gt;
&amp;lt;source lang=cli&amp;gt;&lt;br /&gt;
$TTL  604800&lt;br /&gt;
@     IN       SOA      ns.mo-web.local.   root.mo-web.local. (&lt;br /&gt;
                                 8                ; Serial&lt;br /&gt;
                            604800                ; Refresh&lt;br /&gt;
                             86400                ; Retry&lt;br /&gt;
                           2419200                ; Expire&lt;br /&gt;
                            604800  )             ; Negative Cache TTL&lt;br /&gt;
;&lt;br /&gt;
@       IN      NS         mo-web.local.&lt;br /&gt;
@	IN	A	   192.168.139.128	&lt;br /&gt;
ns      IN      A          192.168.139.128&lt;br /&gt;
www	IN	A	   192.168.139.128&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And finally /etc/bind/zones/rev.0.0.10.in-addr.arpa:&lt;br /&gt;
&amp;lt;source lang=cli&amp;gt;&lt;br /&gt;
$TTL 3D&lt;br /&gt;
@        IN         SOA         ns.mo-web.local.   admin.mo-web.local.  (&lt;br /&gt;
                    2007062001  &lt;br /&gt;
                    28800&lt;br /&gt;
                    604800&lt;br /&gt;
                    604800&lt;br /&gt;
                    86400&lt;br /&gt;
)&lt;br /&gt;
         IN         NS           ns.mo-web.local.&lt;br /&gt;
2        IN         PTR          ubuntu.mo-web.local&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''FTP:'''&lt;br /&gt;
We used vsftpd as ftp server:&lt;br /&gt;
* apt-get install vsftpd&lt;br /&gt;
&lt;br /&gt;
Then we changed the configuration file (/etc/vsftpd.conf) on the following lines:&lt;br /&gt;
&amp;lt;source lang=cli&amp;gt;&lt;br /&gt;
// disable anonymous logins&lt;br /&gt;
anonymous_enable=NO&lt;br /&gt;
// enable login for local users&lt;br /&gt;
local_enable=YES&lt;br /&gt;
// local users will only have access to their home dir&lt;br /&gt;
chroot_local_user=YES&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
restart ftp server&lt;br /&gt;
* service vsftpd restart&lt;br /&gt;
&lt;br /&gt;
Finally we created a user with rights to /var/www/ (by setting home dir to /var/www/):&lt;br /&gt;
* useradd -d /var/www/ -m paul&lt;br /&gt;
* passwd paul&lt;/div&gt;</summary>
		<author><name>Okdios</name></author>	</entry>

	</feed>