Welcome to the Cumulus Support forum.

Latest Cumulus MX release 3.6.10 (build 3086) - 24 June 2020 (please see important announcement regarding releases since 3.5.0)
Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of the NOAA report and Snow Index drop-down menus to 2030)

See the Wiki to download the software or click on the Downloads link in the Forum Banner.

Help with simple local website setup

Other discussion about creating web sites for Cumulus that doesn't have a specific subforum

Moderator: daj

Post Reply
bobmoss
Posts: 11
Joined: Sat 27 Dec 2008 11:02 am
Weather Station: Davis Vantage Pro 2
Operating System: Raspberry PI Zero W

Help with simple local website setup

Post by bobmoss »

Hi,

I'm running Cumulus MX on a raspberry PI and have installed Apache etc., ready to get Cumulus to start updating web files locally in /var/www/html by copying rather than FTP.

I'm following the instruction on the Wiki page https://cumuluswiki.org/a/Simple_Website_setup but it seems to be missing any way to tell it where to save files to if I'm not using FTP and want it to copy files locally.

The customised templates section mentions adding files into the Extra web files, but the simple website page seems to suggest I don't need to do that.

Can anyone help?

Thanks.

water01
Posts: 1913
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: WH1081
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Help with simple local website setup

Post by water01 »

You do with the Extra Web Files in Settings.

Just set the Local File Name and then set the Remote File Name to where you want it copied. If it is a file to be processed (contains web tags) click on process. If it is a realtime click on realtime. Ignore FTP, click on UTF8 and ignore the other two settings unless you feel you need them.

Since you are copying locally it is a bit more labour intensive since you will have to do this for all the standard files.

The other alternative is to set up a FTP client on the PI and set it up to FTP locally will save some effort but may take some time to get going.
David
Image

sfws
Posts: 905
Joined: Fri 27 Jul 2012 11:29 am
Weather Station: Modified Fine Offset
Operating System: Win. 10 PC
Location: The Marches, UK

Re: Help with simple local website setup

Post by sfws »

I believe there are 22 standard files to list in extra web files local column to avoid FTP. All files are in the web folder under where the executables are.

You must list all the .json files (don't need process), but you do need to tick process for all the standard template files (...T.htm) and without process ticked also put moon.png in the local column.

Don't forget that "simple website setup" was
a) written when Cumulus only ran on a windows device, MX had not been invented when that was written
b) to keep it simple it did not describe alternatives, and using FTP was seen as simplest approach

Gregorean
Posts: 21
Joined: Tue 12 May 2020 11:41 am
Weather Station: Davis Vantage Vue
Operating System: BeagleBone Black Rev.C
Location: Amersfoort, The Netherlands
Contact:

Re: Help with simple local website setup

Post by Gregorean »

Hello bobmoss and others, sorry for the correction but the moon.png can't be uploaded via extra webfiles, only via ftp. :(
I also run CumulusMX 3084 locally on a BeagleBone black a kind of RPI, the file structure en setup is exactly the same, the moon.png can be uploaded but doesn't work because the size is normally 14kb via ftp but via extra webfiles it is 25kb and unreadable even with an external viewer.
This should/can be done better via ftp then you don't have to upload the 8 ***.json files separately.
Furthermore I advise you not to use an Apache2 server which is far too ''heavy'' apllication for a simple webserver, I use NGINX and PHP7.3 and Mono myself.
If you have any questions about the installation of NGINX I can hear it, it has been working here for a long time to full satisfaction and very stable. :)

Greetings Sjaak.
Weather Station: Amersfoort-Nieuwland, The Netherlands.
http://element14.serverthuis.nl/
http://element14.serverthuis.nl/cumulusmx/

freddie
Posts: 766
Joined: Wed 08 Jun 2011 11:19 am
Weather Station: Davis Vantage Pro 2
Operating System: Ubuntu 18.04 (LXC container)
Location: Dorrington, Shropshire, UK
Contact:

Re: Help with simple local website setup

Post by freddie »

Gregorean wrote:
Tue 30 Jun 2020 7:42 pm
Hello bobmoss and others, sorry for the correction but the moon.png can't be uploaded via extra webfiles, only via ftp. :(
I disagree. I use extra webfiles to perform a local copy.
Gregorean wrote:
Tue 30 Jun 2020 7:42 pm
the moon.png can be uploaded but doesn't work because the size is normally 14kb via ftp but via extra webfiles it is 25kb and unreadable even with an external viewer.
That is a symptom of having the "process" checkbox ticked.
Freddie
Image

Gregorean
Posts: 21
Joined: Tue 12 May 2020 11:41 am
Weather Station: Davis Vantage Vue
Operating System: BeagleBone Black Rev.C
Location: Amersfoort, The Netherlands
Contact:

Re: Help with simple local website setup

Post by Gregorean »

Hi Freddy,that last thing you write is wrong, if you upload from CumulusMX/web/MoonBaseImage.png and you rename it and upload as moon.png then that doesn't work well your file size is more than double than you let ftp do it, try it out, I've been fighting with this for ages. :?
I do the same as what @bobmoss wants to do, I host 2 websites locally and partially use ftp.
Just tested it when I upload MoonBasel.png via Extra Webfiles as moon.png and ticked ''process'' to the root var/www/html/images then the file is over 25kb and not visible in the index.htm.

Sjaak.
Last edited by Gregorean on Tue 30 Jun 2020 9:06 pm, edited 1 time in total.
Weather Station: Amersfoort-Nieuwland, The Netherlands.
http://element14.serverthuis.nl/
http://element14.serverthuis.nl/cumulusmx/

water01
Posts: 1913
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: WH1081
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Help with simple local website setup

Post by water01 »

But he said
That is a symptom of having the "process" checkbox ticked.
, so what he meant was it shouldn't be ticked and therefore it doesn't process the image.
My guess is you should have Binary ticked as this works better for images of any kind i.e. webcam images etc.
David
Image

sfws
Posts: 905
Joined: Fri 27 Jul 2012 11:29 am
Weather Station: Modified Fine Offset
Operating System: Win. 10 PC
Location: The Marches, UK

Re: Help with simple local website setup

Post by sfws »

Gregorean wrote:
Tue 30 Jun 2020 9:00 pm
if you upload from CumulusMX/web/MoonBaseImage.png and you rename it and upload as moon.png then that doesn't work well your file size is more than double than you let ftp do it,
That is wrong.
It is moon.png that should be in local column, just as my earlier post said. Your posts conflict, between which file you are selecting for here.

MoonBaseImage.png is a full moon image. MX produces moon.png by masking parts of that full moon image with system graphics according to current phase.

The size of moon.png will vary each time it is generated (hourly) because as moon phase varies , that image could be after masking out all but a crescent (perhaps 23kB) or displaying full moon (177kB) as per base image.

Neither has web tags, so neither needs Process ticked. The Process column is simply for indicating whether Cumulus needs to replace web tags by their values as it copies source template file into output file.
water01 wrote:
Tue 30 Jun 2020 9:04 pm
My guess is you should have Binary ticked as this works better for images of any kind i.e. webcam images etc.
Correct, moon.png is an image, and Binary should be selected for a FTP.

I am unsure whether it makes any difference for a copy, but ticking it probably would not cause a problem for copy. I have NOT tested this.

The size issue that Gregorean mentions, when comparing FTP and copy, is because he is comparing uploading two different images if I understand his rather conflicting posts correctly.
Although a size issue can occur when processing images by FTP if Binary is not ticked.
sfws wrote:
Tue 30 Jun 2020 6:37 pm
I believe there are 22 standard files to list in extra web files local column to avoid FTP. All files are in the web folder under where the executables are.

You must list all the .json files (don't need process), but you do need to tick process for all the standard template files (...T.htm) and without process ticked also put moon.png in the local column.
I stick by my earlier post which, I repeat, said it was moon.png to put in local file, as I don't think for copying it depends whether you tick binary or not.

Gregorean
Posts: 21
Joined: Tue 12 May 2020 11:41 am
Weather Station: Davis Vantage Vue
Operating System: BeagleBone Black Rev.C
Location: Amersfoort, The Netherlands
Contact:

Re: Help with simple local website setup

Post by Gregorean »

Ok, that way, clearly... I didn't know that :? I had to tick binary as well as process, I've had times fighting with it that was because I used ftp first and my moon.png and the .json files weren't uploaded. That's why I tried to upload my files anyway, the .json files and the .htm files were no problem but the moon.png just wouldn't work.
Until I found out that I had to use sftp for uploading, and everything worked at once also the moon.png and all .json files, only the .htm files now go through Extra Webfiles.
Now everything works perfectly, thanks to the sftp patch from Mark (thanks again ) in build 3084. :P

Sjaak.
Weather Station: Amersfoort-Nieuwland, The Netherlands.
http://element14.serverthuis.nl/
http://element14.serverthuis.nl/cumulusmx/

bobmoss
Posts: 11
Joined: Sat 27 Dec 2008 11:02 am
Weather Station: Davis Vantage Pro 2
Operating System: Raspberry PI Zero W

Re: Help with simple local website setup

Post by bobmoss »

water01 wrote:
Tue 30 Jun 2020 4:38 pm
You do with the Extra Web Files in Settings.

Just set the Local File Name and then set the Remote File Name to where you want it copied. If it is a file to be processed (contains web tags) click on process. If it is a realtime click on realtime. Ignore FTP, click on UTF8 and ignore the other two settings unless you feel you need them.

Since you are copying locally it is a bit more labour intensive since you will have to do this for all the standard files.

The other alternative is to set up a FTP client on the PI and set it up to FTP locally will save some effort but may take some time to get going.
Excellent, thanks. Will go and have a play this that. It's a shame there isn't a simple tick box/field in the setup page that says "use local copy instead of FTP", it would make things so much easier!

bobmoss
Posts: 11
Joined: Sat 27 Dec 2008 11:02 am
Weather Station: Davis Vantage Pro 2
Operating System: Raspberry PI Zero W

Re: Help with simple local website setup

Post by bobmoss »

sfws wrote:
Tue 30 Jun 2020 6:37 pm
I believe there are 22 standard files to list in extra web files local column to avoid FTP. All files are in the web folder under where the executables are.

You must list all the .json files (don't need process), but you do need to tick process for all the standard template files (...T.htm) and without process ticked also put moon.png in the local column.

Don't forget that "simple website setup" was
a) written when Cumulus only ran on a windows device, MX had not been invented when that was written
b) to keep it simple it did not describe alternatives, and using FTP was seen as simplest approach
Cool, thanks. If I get chance I might update the Wiki to mention this as it mentions it in passing and had me think I had missed a step!

Post Reply