Evan: I got WeeWX to work in a TrueNAS jail today. I was able to set it up with the simulator driver and ran it from the command line (./bin/weewxd + ./bin/wee_reports) with no issues. This setup assumes you are going to use the sqlite database as your datasource. I will list the instructions below this note.
One thing I noticed on your original thread is that you need to do a symbolic link for python3 to python. so I ran this statement below after my package installation to ease my install: ln -s /usr/local/bin/python3 /usr/local/bin/python. Here is the steps I did to get this to work. ===== WEEWX FREEBSD INSTALL INSTRUCTIONS ===== 1. Install these packages: pkg install python3 pkg install py38-pip pkg install py38-configobj pkg install py38-pillow pkg install py38-pyserial pkg install py38-pyusb pkg install py38-cheetah3 pkg install py38-sqlite3 pkg install py38-mysqlclient pkg install py38-ephem 2. create symbolic link for python3 to python ln -s /usr/local/bin/python3 /usr/local/bin/python 3. Grab weewx and decompress it in your home folder. In this example below, we are going to get WeeWX 4.5.1 fetch https://weewx.com/downloads/weewx-4.5.1.tar.gz tar xvfz weewx-4.5.1.tar.gz cd weewx-4.5.1 ./setup.py build ./setup.py install 4. Follow the installation prompts to configure your weewx.conf file. 5. Test out your installation by running these commands in the /home/weewx directory: ./bin/weewxd ./bin/wee_reports 6. Validate you have a /home/weewx/archive/weewx.sdb file and html files located in /home/weewx/public_html directories. ===== END FREEBSD WEEWX INSTALL INSTRUCTIONS ===== let us know how you make out with this setup and if you need any more help. DDJ On Wednesday, September 22, 2021 at 10:48:33 AM UTC-4 Doug Jenkins wrote: > Ok, that helps a bit. > > I have created a jail on my TrueNAS (v12.0.U05) and I will try to get > WeeWX to work with a simulator first. My Jail will be based on FreeBSD 12.2 > > The challenge is getting dependencies installed in Python. I was able to > get Python3 installed and configured by running the following statement in > my new jail: > > pkg install python3. > > I will take a look at this in the afternoon and see if I am successful. If > so, I will share the details. > > DDJ > > On Wednesday, September 22, 2021 at 10:26:40 AM UTC-4 Evan Kimberly wrote: > >> I tried writing a line in make.conf to point to python 3.8 >> >> PYTHON_DEFAULT_VERSION='python3.8' >> >> No luck still getting it to run. >> >> As for hardware access, i plan on using interceptor. From what I've read >> on here, it sounds doable to run weewx in a jail on freebsd. I just need to >> get the thing installed first! >> >> On Wednesday, September 22, 2021 at 10:16:42 AM UTC-4 >> [email protected] wrote: >> >>> Evan: >>> >>> In your jail you will need to install python3 and the packaging through >>> pkg first. You will need to find the FreeBSD equivalents of the required >>> packages as listed in the setup doc ( WeeWX: Installation using >>> setup.py <http://weewx.com/docs/setup.htm>) . >>> >>> Keep in mind that jails usually do not have access to the direct >>> hardware, so USB/serial passthrough maybe tough. >>> >>> It may make sense to setup a VM of Debian Buster on TrueNAS than trying >>> to run this through a jail. WeeWx does not need a lot of resources, so a >>> small VM (2GB, 2 cores) could be sufficient. >>> >>> DDJ >>> >>> >>> >>> On Wednesday, September 22, 2021 at 9:50:04 AM UTC-4 Evan Kimberly wrote: >>> >>>> I just tried that and it is telling me python3 command not found. >>>> >>>> On Wednesday, September 22, 2021 at 12:40:37 AM UTC-4 vince wrote: >>>> >>>>> Try "python3 setup.py build" and see if that works any better. >>>>> >>>>> Basically your system does not have a default "python", which we see >>>>> in some operating systems. >>>>> >>>>> On Tuesday, September 21, 2021 at 9:17:37 PM UTC-7 Evan Kimberly wrote: >>>>> >>>>>> I am still learning my way around bsd and command line in general and >>>>>> am having difficulty getting this up and running. I was reading a >>>>>> separate >>>>>> thread in this group 'FreeBSD / TrueNAS Jail Install Help' and am >>>>>> now stuck. >>>>>> >>>>>> My current steps as follow: >>>>>> Set up jail (In TrueNAS, 12.2-RELEASE-p9) >>>>>> pkg install python38 >>>>>> pkg install py38-cheetah3 >>>>>> pkg install py38-configobj >>>>>> pkg install py38-pillow >>>>>> pkg install py38-sqlite3 >>>>>> pkg install py38-ephem >>>>>> fetch https://weewx.com/downloads/weewx-4.5.1.tar.gz >>>>>> tar xvfz weewx-4.5.1.tar.gz >>>>>> cd weewx-4.5.1 >>>>>> ./setup.py build >>>>>> >>>>>> I get the title error at the last step. I am currently in the >>>>>> directory that setup.py exists in. The thread I was following suggested >>>>>> using python37, but I wasn't able to install those packages. When I run >>>>>> pkg >>>>>> search py37-(whatever) I don't get any results, so i changed up to 38. >>>>>> >>>>>> Any suggestions? >>>>>> >>>>> -- You received this message because you are subscribed to the Google Groups "weewx-user" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/9d72e6c7-46a2-4cc7-bda6-e746cab60950n%40googlegroups.com.
