Created
April 1, 2019 16:41
-
-
Save ravexina/da388a40e27593fe819beda037a7b31f to your computer and use it in GitHub Desktop.
Netplan example configuration and simple usage
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # - - - - - - - - - - - - - - - - - - | |
| # > $ sudo netplay try | |
| # > $ sudo netplan apply | |
| # > $ ip link set ens3 down/up | |
| # > $ ip addr show ens3 | |
| # - - - - - - - - - - - - - - - - - - | |
| # - - - - - - - - - - - - - - - - - - | |
| # Static configuration | |
| # - - - - - - - - - - - - - - - - - - | |
| network: | |
| version: 2 | |
| renderer: networkd | |
| ethernets: | |
| ens3: | |
| dhcp4: false | |
| dhcp6: false | |
| addresses: [192.168.1.10/24] | |
| gateway4: 192.168.1.254 | |
| nameservers: | |
| addresses: [8.8.4.4, 8.8.8.8] | |
| # - - - - - - - - - - - - - - - - - - | |
| # DHCP Configuration | |
| # - - - - - - - - - - - - - - - - - - | |
| network: | |
| version: 2 | |
| renderer: networkd | |
| ethernets: | |
| ens3: | |
| dhcp4: true | |
| dhcp6: false | |
| optional: true | |
| ens4: | |
| dhcp4: true | |
| dhcp6: false | |
| optional: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment