Static IP

Get-NetAdapter
Set-NetIPInterface -InterfaceAlias "Ethernet" -Dhcp Disabled
New-NetIPAddress -InterfaceAlias "Ethernet" -IPAddress 192.168.1.4 -PrefixLength 24 -DefaultGateway 192.168.1.1

Single DNS server

Set-DNSClientServerAddress -InterfaceAlias "Ethernet" -ResetServerAddresses
Set-DNSClientServerAddress -InterfaceAlias "Ethernet" -ServerAddresses 192.168.1.2

Two DNS servers

Set-DNSClientServerAddress -InterfaceAlias "Ethernet" -ResetServerAddresses
Set-DNSClientServerAddress -InterfaceAlias "Ethernet" -ServerAddresses 192.168.1.5,192.168.1.6

See also: Rename a host and join to the domain, Chocolatey Setup and Use