403Webshell
Server IP : 66.29.132.122  /  Your IP : 3.129.69.30
Web Server : LiteSpeed
System : Linux business142.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64
User : admazpex ( 531)
PHP Version : 7.2.34
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/dracut/modules.d/02systemd-networkd/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/dracut/modules.d/02systemd-networkd/module-setup.sh
#!/bin/bash

# called by dracut
check() {
    [[ $mount_needs ]] && return 1

    if ! dracut_module_included "systemd"; then
        derror "systemd-networkd needs systemd in the initramfs"
        return 1
    fi

    return 255
}

# called by dracut
depends() {
    echo "systemd kernel-network-modules"
}

installkernel() {
    return 0
}

# called by dracut
install() {
    inst_multiple -o \
        $systemdutildir/systemd-networkd \
        $systemdutildir/systemd-networkd-wait-online \
        $systemdsystemunitdir/systemd-networkd-wait-online.service \
        $systemdsystemunitdir/systemd-networkd.service \
        $systemdsystemunitdir/systemd-networkd.socket \
        $systemdutildir/network/99-default.link \
        networkctl ip

        #hostnamectl timedatectl
        # $systemdutildir/systemd-timesyncd \
        # $systemdutildir/systemd-timedated \
        # $systemdutildir/systemd-hostnamed \
        # $systemdutildir/systemd-resolvd \
        # $systemdutildir/systemd-resolve-host \
        # $systemdsystemunitdir/systemd-resolved.service \
        # $systemdsystemunitdir/systemd-hostnamed.service \
        # $systemdsystemunitdir/systemd-timesyncd.service \
        # $systemdsystemunitdir/systemd-timedated.service \
        # $systemdsystemunitdir/time-sync.target \
        # /etc/systemd/resolved.conf \


    # inst_dir /var/lib/systemd/clock

    grep '^systemd-network:' /etc/passwd 2>/dev/null >> "$initdir/etc/passwd"
    grep '^systemd-network:' /etc/group >> "$initdir/etc/group"
    # grep '^systemd-timesync:' /etc/passwd 2>/dev/null >> "$initdir/etc/passwd"
    # grep '^systemd-timesync:' /etc/group >> "$initdir/etc/group"

    _arch=$(uname -m)
    inst_libdir_file {"tls/$_arch/",tls/,"$_arch/",}"libnss_dns.so.*" \
                     {"tls/$_arch/",tls/,"$_arch/",}"libnss_mdns4_minimal.so.*" \
                     {"tls/$_arch/",tls/,"$_arch/",}"libnss_myhostname.so.*" \
                     {"tls/$_arch/",tls/,"$_arch/",}"libnss_resolve.so.*"

    for i in \
        systemd-networkd-wait-online.service \
        systemd-networkd.service \
        systemd-networkd.socket
#       systemd-timesyncd.service
    do
        systemctl -q --root "$initdir" enable "$i"
    done
}


Youez - 2016 - github.com/yon3zu
LinuXploit