Check out my first novel, midnight's simulacra!
FreeBSD: Difference between revisions
From dankwiki
No edit summary |
No edit summary |
||
Line 21: | Line 21: | ||
No updates needed. | No updates needed. | ||
[zaebros](0) $ </pre> | [zaebros](0) $ </pre> | ||
==Getting <tt>sudo</tt>== | |||
Install <tt>security/sudo</tt> from the Ports Collection. Your sudoers file lives in <tt>/usr/local/etc/sudoers</tt>. | |||
To add a user to the <tt>wheel</tt> group, use <tt>pw group mod wheel -m USER</tt> |
Revision as of 12:14, 25 December 2019
I began using FreeBSD upon starting employment at CipherTrust (later Secure Computing and now McAfee). Coming from ~8 years of Linux background, FreeBSD represented all of unpleasant surprises, interesting new solutions, and my first real new exploration through the UNIX/POSIXverse.
Building Ports as a User
Read the ports(7) man page. Unfortunately, that doesn't appear to document the INSTALL_AS_USER or PORT_DBDIR environment variables. There's two ways to do this:
- Replicate a Ports tree (for instance, using the portsnap tool with the -d and -p flags) of your own, and export PORTSDIR to point there. If you intend to do this, it's a good idea to copy and modify portsnap.conf; this can be specified to portsnap via the -f flag.
[zaebros](0) $ mkdir var/db/portsnap [zaebros](0) $ portsnap -d ~/var/db/portsnap -p ~/usr/ports fetch Looking up portsnap.FreeBSD.org mirrors... using portsnap2.FreeBSD.org Fetching public key... done. Fetching snapshot tag... done. Fetching snapshot metadata... done. Fetching snapshot generated at Mon Dec 29 01:47:08 UTC 2008: 6bf58ae284670960568d398d71f819924bd7d85ff37d9e100% of 54 MB 123 kBps 00m00s Extracting snapshot... done. Verifying snapshot integrity... done. Fetching snapshot tag... done. Latest snapshot on server matches what we already have. No updates needed. [zaebros](0) $
Getting sudo
Install security/sudo from the Ports Collection. Your sudoers file lives in /usr/local/etc/sudoers.
To add a user to the wheel group, use pw group mod wheel -m USER