Own Package Repository
-
Hello,
Problem 1: pkg_tester.php
Problem 2: Connection from pfSense to RepositorypfSense Version 2.1; Wampserver
The approach:
-following the steps at https://doc.pfsense.org/index.php/Creating_Your_Own_Package_Repository
-> Step3 works test.php. It appears "Array ([0] => foo [1] => baz)"
-> Step3 pkg_tester.php not work. In addition I have not found a useful solution in the internet and there are error messages I can not do anything.
(Call to a member function kindof () on a non-object etc.)The connection to the repository shows the following: "Unable to retrieve package info from …". From the pfSense, this address can successfully ping.
already read and tried ...
https://forum.pfsense.org/index.php?topic=75163.0I appreciate any response ;-)
In the attachement you see the content of the root folder.
Many thanks!
Fox
-
If pkg_tester.php doesn't work then your box won't be able to retrieve packages from there. Please post the complete errors given.
I once set up a custom repo a long time ago and my biggest recollection is that it took ages and I made many mistakes. ::)
Steve
-
"it took ages" - YES! :-)
It seems to me that I will not take a step forward.
In the attachement you see the errors. They are all in xmlrpc_client.inc.
-
Hmm, I think this is beyond me. It's along while since I tried it and reading through the development forum there seem to have been a number of changes which render my own experience obsolete.
Anyone else want to chime in here? :-\Steve
-
Those paths appear to be from a Windows install. I think you will do much better using a FreeBSD machine with Apache. I created a FreeBSD 8.3 virtual machine and installed Apache and PHP on it. You then clone the XMLRPC stuff from the pfsense-tools repository (once you have requested and been granted access). Once you do that, and wave a magic wand and say the magic words, it may start working… ;D
OK, just kidding on the magic stuff. However, it did take me quite a bit of fiddling around to get it working. I'm not sure how successful you will be on Windows due the potential differences in PHP. From my experience, the package repository must have a specific directory structure in order to work correctly. That structure is driven by dependencies within the XMLRPC files.
Bill
-
Yes, I was using FreeBSD 8.1 I think. I had to make some changes to the apache config to get it to run the php rather than serve it if I recall.
Steve
-
I will try :-)
-
here is my result.
-
Looks good, is the repo working?
Steve
-
Thanks for helping so far!
For running pkg_tester.php I had to add one file in the folder "pfSense/packages". I copied the file "pkg_config.8.xml" and renamed in "pkg_config.xml. Otherwise it did not work because it can not find the version. This is not normal!? ;-)
I used the "tag" code from pfSense/xmlrps-server/RELENG_2_1_3 and pfSense/packages/RELENG_2_1_5.
The repo is not working. The connection to the repository shows the following again: "Unable to retrieve package info from …". From the pfSense, this address can successfully ping. The folder structur of the root you can see in the attachment.
-
I also tried these two types…it remains exciting.
-
The output from pkg_tester looks like it's not in the server root but inside a pfSense folder. Is that still the case?
Steve
-
It is in both now.
localhost/pfSense/pkg_tester.php
and
localhost/pkg_tester.php
-
It works! :-)) mistake in virtual machine
-
Version 2.0 and Version 2.1 works !
but 2.1.5 the latest version does not want so far…
-
Nice. :)
2.0 and 2.1 working but later versions not working are the exact symptoms described in the thread you linked to.Steve
-
To run pfSense Version 2.1.5 the URL must not be an ip address. It has to be a name. To resolve the address in an ip you can make an entry in /etc/hosts. ;)
To test the repo I downloaded a package. I changed the URL in <depends_on_package_base_url>.
<depends_on_package_base_url>https://Webserver/packages/8/All/</depends_on_package_base_url>
This works, but I can not change the URL from the <config_file><config_file>https://packages.pfsense.org/packages/config/phpsysinfo/phpsysinfo.xml</config_file>
I think the problem is, that my Webserver can not show the xml file.</config_file></depends_on_package_base_url>
-
I followed the instructions at http://codenaut.blogspot.de/2009/03/setup-apache-to-serve-xml-files.html.
I added these two lines in httpd.conf within "<ifmodule mime_module="">"
AddType application/xhtml+xml .xhtml .xml
AddEncoding xhtml xml
still not works - an idea?
In the Attachment you see the outputs from Firefox and FreeBSD Browser - different outputs…
localhost/packages/config/phpsysinfo/phpsysinfo.xml
The output is not the same to
https://packages.pfsense.org/packages/config/phpsysinfo/phpsysinfo.xml
</ifmodule> -
I do remember having to make some chage to the Apache config to allow it to serve files rather than interpreting them but I'm fairly sure that was php. Hmm, could be wrong it was a long time ago. :-\
Steve
-
I believe you mean the .htaccess file.
The Browsers show the files different, so I downloaded the file to see exactly what is wrong.
I get the file from my Webserver without the content in brackets.–-------------------------------------------
It works! :-)There are two MIME Types of XML
AddType text/xhtml+xml .xhtml .xml
AddEncoding xhtml xml