{"id":159,"date":"2018-04-24T19:16:22","date_gmt":"2018-04-24T19:16:22","guid":{"rendered":"http:\/\/www.project34.net\/?p=159"},"modified":"2018-04-24T19:16:22","modified_gmt":"2018-04-24T19:16:22","slug":"osmc-2018-x-with-spotweb","status":"publish","type":"post","link":"https:\/\/www.project34.net\/index.php\/2018\/04\/24\/osmc-2018-x-with-spotweb\/","title":{"rendered":"OSMC 2018.X with Spotweb"},"content":{"rendered":"<p>After a while it was time to reinstall my Raspberry pi OSMC installation.\u00a0The installation was corrupt after some testing with different pieces of software. Well it was time to do a new installation.<\/p>\n<p>After a while i found out that OSMC had upgraded to PHP version 7, while Spotweb was only working with PHP version 5. So what to do? The default installations work great when you have a default PHP version 5, search on the internet, combine a couple of guides so you can &#8220;upgrade&#8221; to PHP 5. And to let people also have fun with Spotweb, here is the guide.<\/p>\n<p>First update everything to the latest version:<br \/>\n<strong>apt-get update &amp;&amp; apt-get dist-upgrade<br \/>\n<\/strong><\/p>\n<p>Add the following line to your \/etc\/apt\/sources.list:<br \/>\n<strong>deb http:\/\/mirrordirector.raspbian.org\/raspbian\/ jessie main contrib non-free rpi<br \/>\n<\/strong>Back on the command line execute:<br \/>\n<strong>wget -q -O &#8211; http:\/\/mirrordirector.raspbian.org\/raspbian.public.key |apt-key add<\/strong><br \/>\nAfter that do an:<br \/>\n<strong>apt-get update &amp;&amp; apt-get dist-upgrade<br \/>\n<\/strong>If everything is ok, nothing will be updated.<\/p>\n<p>Now install php5, mysql client and apache2:<br \/>\n<strong>apt-get install php5-mysql php5 apache2 php5-curl php5-gd php5-gmp\u00a0<\/strong><br \/>\n(Please note, mysql (mariadb in fact) is running on another server)<br \/>\nAccept the changes by pressing: <strong>Y\u00a0<\/strong>and press enter.<\/p>\n<p>You probably get an error, that&#8217;s because OSMC has a server running on the same webport. Let&#8217;s change that:<br \/>\n<strong>nano \/etc\/apache2\/sites-enabled\/000-default.conf<\/strong><br \/>\nThe first line ends with *:80, change this to *:8080 and save it (CTRL+X -&gt; y -&gt; Enter)<br \/>\nThen we need to edit the ports file from apache:<br \/>\n<strong>nano \/etc\/apache2\/ports.conf<\/strong><br \/>\nchange the line that states Lines 80 and change it to Lines 8080 and save it\u00a0(CTRL+X -&gt; y -&gt; Enter).<\/p>\n<p>Now we can start apache2:<br \/>\n<strong>\/etc\/init.d\/apache2 start<br \/>\n<\/strong>Try to connect to the website using the ip-address with the portnumber added:<\/p>\n<pre class=\"lang:sh decode:true\">192.168.178.123:8080<\/pre>\n<p>(ip-address can change to your setup) If everything went as planned you have a website.<\/p>\n<p>Now we configure PHP:<br \/>\nWe&#8217;ve got to change the timezone:<\/p>\n<pre class=\"lang:sh decode:true\" title=\"Modifying timezone from PHP\">sed -i \"s\/^;date.timezone =.*\/date.timezone = Europe\\\/Amsterdam\/\" \/etc\/php5\/*\/php.ini<\/pre>\n<p>(Change the timezone to your own, this is my timezone)<\/p>\n<p>The next part is a bit difficult, because as i said, my database is running on another server, and that part is already installed. look at:\u00a0https:\/\/github.com\/spotweb\/spotweb\/wiki\/Install-Spotweb-on-Ubuntu-12.04-LTS-(Precise-Pangolin)-(english) for the configuration, part of this post is also comming from there btw.<\/p>\n<p>Based upon the other website, i hope you have configured the SQL part.<\/p>\n<p>Now you have 2 options, installing spotweb using apt-get, but i wouldn&#8217;t recommend it. The version of spotweb on the repository is of 2013 and although spotweb from github isn&#8217;t actively maintained anymore, it&#8217;s still more recent then using apt-get.<\/p>\n<p>To install spotweb using github do the following:<\/p>\n<pre class=\"lang:sh decode:true\" title=\"Installing spotweb from github using shell\">wget https:\/\/github.com\/spotweb\/spotweb\/tarball\/master\r\ntar -xvzf master\r\nsudo mv spotweb-spotweb-* \/var\/www\/html\/spotweb\r\nrm master\r\ncd \/var\/www\/html\/spotweb\r\nmkdir cache\r\nchown www-data:www-data * -R<\/pre>\n<p>Now we can connect to spotweb using the website:<\/p>\n<pre class=\"lang:sh decode:true\">192.168.178.123:8080\/spotweb\/install.php<\/pre>\n<p>On the first page everything should be fine, the only options that maybe need some attention are:<br \/>\n<strong>Database support:\u00a0<\/strong>At least one of the database components should give OK, the others can be &#8220;NOT OK&#8221;.<br \/>\n<strong>Own settings file<\/strong>: i don&#8217;t really make a custom settings file, so that can stay as &#8220;NOT OK&#8221;.<br \/>\nClick &#8220;Next&#8221;<\/p>\n<p>The database components need to be changed to accomodate your settings. Like i said my database is on another server, so i changed the settings to the other server. When done, click verufy database and if everything is done correctly, you continue.<\/p>\n<p>Then enter the information of your usenet provider. You can select a set of preconfigured usenet providers or ad a custom one (last item of the pulldown menu). When done click verify.<\/p>\n<p>In the next menu you select what type of spotweb enviroment you want. In my case I checked &#8220;Single User&#8221; and added my info and clicked create system.<\/p>\n<p>If everything goes ok you will get a new screen that gives you the content of your\u00a0dbsettings.inc.php. If you are using a program to make a connection to your server, you can copy paste the content. In the worst case you need to type it.<\/p>\n<pre class=\"lang:sh decode:true\">cd \/var\/www\/html\/spotweb\r\nnano dbsettings.inc.php\r\n&lt;copy paste the website content&gt;\r\nCTRL+X -&gt; Y -&gt; ENTER<\/pre>\n<p>While you are in a shell also do the following:<\/p>\n<pre class=\"lang:sh decode:true\">cd bin\r\nphp upgrade-db.php\r\nphp upgrade-db.php\r\n<\/pre>\n<p>(Yes run the last line twice. An index wasn&#8217;t created, so running it twice fixed that issue)<br \/>\nThen switch back to your website and click on the link &#8220;Visit your spotwebsite&#8221;<\/p>\n<p>DONE!!<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>Used resources:<br \/>\nhttps:\/\/github.com\/spotweb\/spotweb\/wiki\/Install-Spotweb-on-Ubuntu-12.04-LTS-(Precise-Pangolin)-(english)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>After a while it was time to reinstall my Raspberry pi OSMC installation.\u00a0The installation was corrupt after some testing with different pieces of software. Well it was time to do a new installation. After a&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-159","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/posts\/159","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/comments?post=159"}],"version-history":[{"count":3,"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/posts\/159\/revisions"}],"predecessor-version":[{"id":164,"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/posts\/159\/revisions\/164"}],"wp:attachment":[{"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/media?parent=159"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/categories?post=159"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.project34.net\/index.php\/wp-json\/wp\/v2\/tags?post=159"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}