Socket
Socket
Sign inDemoInstall

etc-hosts

Package Overview
Dependencies
16
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    etc-hosts

Adds a js controlled section to your etc/hosts file. Common usecase is to autosetup some hostnames in situations a DNS does not fit.


Version published
Weekly downloads
2
increased by100%
Maintainers
1
Install size
1.02 MB
Created
Weekly downloads
 

Readme

Source

#etc-hosts for simple "etc/hosts" management.

Adds a js controlled section to your etc/hosts file. Common usecase is to autosetup some hostnames in situations a DNS does not fit.

var etcHosts = requir('etc-hosts');
var hosts = [{ip:'192.168.33.2',names:['dev.box']}];
etcHosts.write(hosts);
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting.  Do not change this entry.
##

127.0.0.1	localhost
255.255.255.255	broadcasthost
::1             localhost
fe80::1%lo0	localhost


##the section below is manged by etc-hosts
#box:start
172.17.0.18 4e9c501ba7d8
172.17.0.12 8b40e285bf38
172.17.0.11 09e4ddb124ec
172.17.0.10 c3702209342e
172.17.0.8 4e1802affe5c
#box:end

FAQs

Last updated on 19 Mar 2015

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc