PHP 7.4.33
Preview: darwin.py Size: 529 B
/home/godevadmin/public_html/upload_images/home/000~ROOT~000/lib/fm-agent/dependencies/phacter/darwin.py

# This software may be freely redistributed under the terms of the GNU
# general public license.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

import os
import netifaces

def ipaddress():
    return netifaces.ifaddresses('en0')[2][0]['addr']
def fqdn():
    return 'server02.example.com'
def processorcount():
    return int(os.popen('sysctl -n hw.ncpu').read())

Directory Contents

Dirs: 1 × Files: 4

Name Size Perms Modified Actions
utils DIR
- drwxr-xr-x 2025-06-19 05:07:59
Edit Download
529 B lrw-r--r-- 2025-06-18 20:44:50
Edit Download
5.62 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download
562 B lrw-r--r-- 2025-06-18 20:44:50
Edit Download
1.98 KB lrw-r--r-- 2025-06-18 20:44:50
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).