User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Sat Jan 03, 2015 9:16 pm

@Lob0426

Good point on spammer registration - I think I'll go ahead and configure the blacklist settings i have from my main server, seems to keep everything at bay for the last 2 years. Though... a plugin may be the better option as these settings might be over-rided when the import feature is used to import a different site.

Well I think for now I'll just configure it without the spam registration plugin and do some testing - As far as caching I use WP super cache on the PressPi image. I considered adding a minify plugin as well - but I know some premuim themes have a built in minify API and I didn't want that conflicting and causing problems. ( thrive themes comes to mind here )... But perhaps I am over thinking that one.

In any event - I installed fail2ban - Seems to test ok, kicking me out after 6 failed login attempts via putty. As far as phpmyadmin goes...still working on getting that going and having some difficulty. But I'll sort it out soon enough i'm sure :)
Last edited by Rionoskae on Sat Jan 03, 2015 9:46 pm, edited 1 time in total.

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Sat Jan 03, 2015 9:20 pm

Also I just noticed with fail2ban if you fail 6 times to login it seems you are permanently banned from logging in via SSH from that IP. Seems good from a security standpoint - but now i have no idea how to fix it :( haha

*Few minutes later...*
Hmm nvm - it seems that is native security as the fail2ban service was stopped the whole time... Hmm

Update:
Ok... I think I got the install directions sorted out for everything I'd like to add - Going to re-image, start fresh and start building 1.6.

Using the following resource for anti-spam implementation (most likely via simple firewall) https://github.com/splorp/wordpress-comment-blacklist . It seems to be the most elegant solution as it also has an added layer of authentication, can be easily disabled if the user would like to use a different solution and works independently of askimet ( which i still encourage users to setup) but hey... trying to get everything working out of the box.

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Sun Jan 04, 2015 2:13 pm

1.6 is now live :)

Changes in 1.6:
1.) Installed PHPmyadmin. It can be accessed via http://presspi:81 , this was an intentional implimentation of phpmyadmin to improve security and reduce automated attacks via the usual login url. (IE - http://ip_address/phpmyadmin)
2.) Installed Raspcontrol. Raspcontrol is an awesome interface that gives you a quick heads up display of the resources being used by your system, services running & more. Great way to keep an eye on the health of your Pi, and an easy tool to help users determine when they have out grown the Pi as a hosting solution.
3.) Installed WP Simple Firewall Plugin. As mentioned in the previous post - This one plugin will fill a number of important roles in the image. Namely an added layer of authentication during login & an automated comment blacklist capability that functions independent of Askimet.

Hope you Enjoy 1.6 everyone :)
~Cheers

User avatar
Lob0426
Posts: 2156
Joined: Fri Aug 05, 2011 4:30 pm
Location: Susanville CA.
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Sun Jan 04, 2015 5:42 pm

Sounds good. I will have to look at both raspcontrol and WP firewall. I might look at the phpMyAdmin too.
512MB version 2.0 as WordPress Server
Motorola Lapdock with Pi2B
Modded Rev 1.0 with pin headers at USB

http://rich1.dyndns.tv/
(RS)Allied ships old stock to reward its Customers for long wait!

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Mon Jan 05, 2015 9:11 pm

Rionoskae, I tried unzipping both 1.6 and 1.5 with Windows extraction wizard.
I get the message "Unknown compression method"!
What did you use to zip these. I can't extract either of 'em.

Edit: Never mind. I installed 7-zip. It seems to be extracting
them with no problem. Don't know why Windows
couldn't do it.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Mon Jan 05, 2015 11:24 pm

Offcenter wrote:Rionoskae, I tried unzipping both 1.6 and 1.5 with Windows extraction wizard.
I get the message "Unknown compression method"!
What did you use to zip these. I can't extract either of 'em.

Edit: Never mind. I installed 7-zip. It seems to be extracting
them with no problem. Don't know why Windows
couldn't do it.
Hmm..that is odd - I used the built in windows compress to .zip it. If anyone else reports issues with it, I'll go ahead and re-compress + upload :)

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Mon Jan 05, 2015 11:31 pm

Rionoskae, it could be because I'm still running Windoze XP. Might have an older version
of the compression software.
(I believe, if it ain't broke, don't fix it. LOL!!)
So far, XP does everything I need to do.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 06, 2015 3:47 pm

Rionoskae, I have another problem.
I tried to run Dweeber's "rpi-wiggle" bash script and all I keep getting is
"command not found".
http://rpi.tnet.com/project/scripts/rpi-wiggle
You DID leave Bash intact in PressPi, didn't you?
Is it me?
Can't figure out why it won't run.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 06, 2015 4:18 pm

I did leave everything intact in the image - It looks like that script just expands drive space...Why don't you just use sudo raspi-config ?

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 06, 2015 4:27 pm

Dweeber's script expands the drive space, but not quite to the full size of the card.
This way, when you make a backup image, you are guaranteed that it will fit on
your backup SDcard, even if the card is slightly smaller than your original.
Read his explanation on the link site that I posted. He explains it a lot
better than I can.
Many people have had trouble with moving the image to a second card and
find that it won't fit because the second card does not have "quite as much"
space as the original.
I've used this script before on my B model and it worked fine.
But for some reason, it won't even run on my B+.
I keep getting "Command not found".

Raspi-config uses ALL the space on the card. If your new card is even a few bytes smaller,
the image will not fit.

But WHY won't the script run?

P.S. I tried leaving Dweeber a message on his website but he hasn't gotten
back to me. Looks like he hasn't been on this forum in over a year.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 06, 2015 9:14 pm

SOLVED
The script was not executable!
Did "sudo chmod +x rpi-wiggle" and Zingo! We're ready for lunch. (Line from an old Abbot and Costello movie) LOL!
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Update: Moving right along!

Sat Jan 10, 2015 7:27 pm

Rionoskae, just a note to let you know that I'm moving right along with your system!
(Like I said, I'm a bit slow with this stuff!)
I have your system all installed and it seems to be working fine.
Then, following the excellent tutorial here:
http://www.raspberrypi.org/forums/viewt ... 29&t=44177
I moved the entire file system except for "/boot" to the
500 gig hard drive attached to my B+.
Thanks again for the great Presspi package.
I hope you don't mind, but I'll be having a few more
questions for you on how to actually use what I now have installed.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Sun Jan 11, 2015 5:50 pm

Thats great :)

Thanks for posting that tutorial here for others to follow - I'm sure others would be interested in setting up something similar. Feel free to ask any questions as you go - I'll do my best to answer what I can!

User avatar
Lob0426
Posts: 2156
Joined: Fri Aug 05, 2011 4:30 pm
Location: Susanville CA.
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Mon Jan 12, 2015 3:27 am

Setting up to run from a USB stick or a USB HDD is relatively simple. If you are worried about card corruption make sure you back up /boot when you backup. Most of my corruptions were the /boot. easy to fix by coping back if you backed them up. I have not had any corruptions in quite a while. The server may get knocked out but usually just takes a restart.
http://rich1.dyndns.tv/?page_id=76
Overall it has been really reliable!

My server is plugged into a UPS along with the router and the second Ethernet hub. My main computer has its own UPS. There have been times when the power went out and the only thing that told me was the UPS beeping, well and the dogs barking at it because it was beeping, and the wife yelling at the dogs who were barking at the beeping UPS, ........ :lol:

I installed raspcontrol onto my server. It shows I am using no swap, but it is only reporting the 100MB swap (dphys-swapfile) that is in Raspbian. It does not show the USB stick (512MB) that is supposed to be the actual swap. I need to see if I can figure out how to edit it to look at the right place. It also reported that the USB stick was not mounted. I installed USB Mount.

Code: Select all

sudo apt-get install usbmount
So it auto-mounts now. It used to mount so I must have changed something and killed it.
512MB version 2.0 as WordPress Server
Motorola Lapdock with Pi2B
Modded Rev 1.0 with pin headers at USB

http://rich1.dyndns.tv/
(RS)Allied ships old stock to reward its Customers for long wait!

User avatar
Lob0426
Posts: 2156
Joined: Fri Aug 05, 2011 4:30 pm
Location: Susanville CA.
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Mon Jan 12, 2015 4:59 am

My brother had something go wrong at the change password stage. He was getting the good old "trouble establishing database".

We had a hard time finding the location of the WordPress files folder as installed in NGINX. It is at;
/usr/share/nginx/www
We needed to fix wp-config.php. It is fixed now. There is no "wordpress" folder, the files and folders are in WWW.

Thought people might like to know in case they needed to find it!

I am playing with it now too.
512MB version 2.0 as WordPress Server
Motorola Lapdock with Pi2B
Modded Rev 1.0 with pin headers at USB

http://rich1.dyndns.tv/
(RS)Allied ships old stock to reward its Customers for long wait!

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 13, 2015 12:32 am

Wow! I'm still getting nowhere with this.
Maybe first I should state my goal with this project.
I want to have a website of static pages. (NO blogs, NO forms, NO interactive anything)
And I want to use Wordpress to be able to add new pages to the site easily.

Presently, I have a small website running with Lighttpd on an older model B here:
http://unclegeorge.no-ip.org

I guess my first question will be.....
What directory do put my existing pages in for Nginx to find them?
I have read several sites that claim to explain configuring Nginx, but
they are all written in jibberjabber. I can't understand any of it or
find any useful info for a beginner.
I also found an Nginx forum, but it appears to be dead. Many people
ask questions, but no one answers any of them.

Second question,
What file do I edit to tell Nginx what port to listen to?
I'm running my site at home via NO-IP, so port 80 is blocked
by my ISP.

I'll have more questions later, but this will do for now.
Thanks guys.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 13, 2015 1:39 am

Glad you asked! If your current site is WordPress I urge you to use the built-in Site migration plugin, I promise it's the easiest way.

As far as port access... I'm not sure off the top of my head, maybe someone else can chime in here:) but if I had to guess, I would imagine it's in the nginx config file.

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Tue Jan 13, 2015 1:51 am

No, my present site is not wordpress. It's just plain html pages that I typed up on Notepad.
And I don't have a "domain". I'm just using NO-IP to redirect people to my dynamic IP address.
So I can't migrate it. What I can do is just copy all of the files into the proper directory....
if I could find it.
Yes, I'm sure there must be some sort of nginx config file, but I have no idea where to
find it.
Hopefully someone else can help.
Thanks.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Rionoskae
Posts: 204
Joined: Thu Mar 06, 2014 5:40 pm
Location: WI
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 12:27 am

Offcenter wrote:No, my present site is not wordpress. It's just plain html pages that I typed up on Notepad.
And I don't have a "domain". I'm just using NO-IP to redirect people to my dynamic IP address.
So I can't migrate it. What I can do is just copy all of the files into the proper directory....
if I could find it.
Yes, I'm sure there must be some sort of nginx config file, but I have no idea where to
find it.
Hopefully someone else can help.
Thanks.
Hmm...that is a bit tougher. Well I'll tell you what - If you want to upload your site to someplace like Gdrive or dropbox, I'll figure it out and write a complete post on how to import these types of site into PressPi.

PM me or shoot me an e-mail on my contact page if you care to take me up on this offer :)

Alternatively, If you just need the directory it should be: /usr/share/nginx/www

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 3:09 am

Thanks Rionoskae. I'll try the directory you suggested first.
If that doesn't work, I'll take you up on your offer.
Thanks again!!

I'm sure that once I get a few of the basics down, I'll be able to
figure out the rest on my own.
At least that gives me a place to start.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
Lob0426
Posts: 2156
Joined: Fri Aug 05, 2011 4:30 pm
Location: Susanville CA.
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 4:39 am

Placing your static pages in that folder will not display them automatically. wordPress is the default right now. You would have to delete everything from the folder and then have an index file. You can copy the text and such and paste it into a Wordpress post or page. Then add the pictures, if any, to the media then put them in the pages. The cache plugin basically makes the pages, not posts, display like static pages. Posts are always dynamic.

Most of my information starts as a post then is converted to a page. Then they are added to the cache by clicking a button. Your HTML pages will not be able to be edited by WordPress.

I started with HTML pages in Apache then converted them, by copy and paste, to WordPress. It is faster than recreating the pages by typing them back in. You may have to change some of the formatting or remove specialized code.
512MB version 2.0 as WordPress Server
Motorola Lapdock with Pi2B
Modded Rev 1.0 with pin headers at USB

http://rich1.dyndns.tv/
(RS)Allied ships old stock to reward its Customers for long wait!

User avatar
Offcenter
Posts: 182
Joined: Wed Jul 31, 2013 4:57 pm
Location: Northwestern New Jersey USA

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 10:53 am

Lobo, I do not want to edit my existing pages with Wordpress.
I just want to keep them as they are, then add NEW pages
to the website with Wordpress.
My home page is already named "index.html" and should be
the first page displayed.
Edit: I'm not sure what you are referring to by "posts", but if
you mean a blog, I do NOT want a blog. There will be no posts,
only static pages.
George in New Jersey.
(learning a little bit every day.)
(and darned confused most of the time!)

User avatar
iinnovations
Posts: 621
Joined: Thu Jun 06, 2013 5:17 pm

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 2:25 pm

Offcenter wrote:Lobo, I do not want to edit my existing pages with Wordpress.
I just want to keep them as they are, then add NEW pages
to the website with Wordpress.
My home page is already named "index.html" and should be

the first page displayed.
Edit: I'm not sure what you are referring to by "posts", but if
you mean a blog, I do NOT want a blog. There will be no posts,
only static pages.
I think you're kinda missing the point of a Wordpress installation. When people such as yoirself move to Wordpress, they typically try to match the theme to their current site and add in text content to create Wordpress pages.

Besides the site configuration woes of WP and non-WP pages side-by-side, you will have theme inconsistency that will be very undesirable. Besides, the point is to manage all content from WP's easy to use interface.

Just bite the bullet and convert all of your existing content.

C
CuPID Controls :: Open Source browser-based sensor and device control
interfaceinnovations.org/cupidcontrols.html
cupidcontrols.com

User avatar
Lob0426
Posts: 2156
Joined: Fri Aug 05, 2011 4:30 pm
Location: Susanville CA.
Contact: Website

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 6:02 pm

Your existing pages will be in the /usr/share/nginx/www folder. The WordPress Posts and Pages are stored in the MySQL database. How do you propose to link them into one site?

WordPress uses PHP not HTML.

Posts are the "blog" that you see when opening the WordPress site. Pages are seperate from the "blog". You can use the primary "blog" to display links to the pages. You use the pages widget to create links to your pages. You do not have to create a "post" to have a "page" you can create just pages.

You could very easily use the first, and only, "post" to describe your site then only use "pages" to display your content. As I said before the caching "plugin" can be used to makes the "pages" serve as static pages.

Otherwise what you should do is load Raspbian fresh then install NGINX. This way you will not have a bunch of stuff you will not need to do what you want. To serve HTML "pages" you do not need to install PHP or MySQL. Of course you will then have to type in the HTML by hand or use an editor.

I have built both types of sites. WordPress is just as fast, if configured properly, at serving your site. It is much quicker and easier to get your new content up, without having to use an editor and transferring everything by FTP. You can drag and drop images into the media area. WordPress has its own FTP just for this purpose!
512MB version 2.0 as WordPress Server
Motorola Lapdock with Pi2B
Modded Rev 1.0 with pin headers at USB

http://rich1.dyndns.tv/
(RS)Allied ships old stock to reward its Customers for long wait!

User avatar
iinnovations
Posts: 621
Joined: Thu Jun 06, 2013 5:17 pm

Re: Turn-key WordPress Server Image - PressPi

Wed Jan 14, 2015 7:43 pm

Lob0426 wrote:WordPress is just as fast, if configured properly, at serving your site.
This is, quite simply, silly, especially if you are using nginx.

C
CuPID Controls :: Open Source browser-based sensor and device control
interfaceinnovations.org/cupidcontrols.html
cupidcontrols.com

Return to “Networking and servers”

Who is online

Users browsing this forum: No registered users and 15 guests