0

I've created a jail to host my webserver/blog, but when attempting to build any port, I consistently get the message "portsnap: Directory is not writable: /usr/ports".

Attached is a screen capture of my console outputs attempting to portsnap fetch/extract/update console screen cap

I'm not certain how to deal with this. installing from pkg works, but I want ports so that I can build my own binaries (also, to understand what the heck is going on and how to resolve it).

SteveMustafa
  • 429
  • 1
  • 5
  • 11
  • The easy answer is "Don't build ports in a Jail". Build the package on the base system, or using Poudriere. Then install the packages you built in the jail. – Chris S Nov 01 '14 at 15:06
  • Interesting. How would you go about that? Wouldn't that also be possible by mounting ports inside the jail, permitting access to the build? – SteveMustafa Nov 01 '14 at 15:13
  • In the port's directory `make package` and the package will be dumped in `/usr/ports/packages/`. [Setting up and using Poudriere](https://www.freebsd.org/doc/handbook/ports-poudriere.html) isn't very hard either, and makes rebuilding packages for updates easier. – Chris S Nov 01 '14 at 16:08

1 Answers1

0

The best idea - don't build packages in jail.

You could use pkg , or pkgng

But, if you want, create this dir

mkdir /usr/ports

And if its needed you could change permissions

chmod ... /usr/ports
Korjavin Ivan
  • 2,250
  • 2
  • 26
  • 41