Skip to content

Instantly share code, notes, and snippets.

@mhahl
Created July 9, 2015 10:31
Show Gist options
  • Save mhahl/e7121bf99629862f10fa to your computer and use it in GitHub Desktop.
Save mhahl/e7121bf99629862f10fa to your computer and use it in GitHub Desktop.
Network VLAN Setup
#!/bin/bash
nmcli con add type vlan con-name "VLAN10 Managment" id 10 dev enp0s20f1 ip4 10.0.10.1/24
nmcli con add type vlan con-name "VLAN20 Private" id 20 dev enp0s20f1 ip4 10.0.20.1/24
nmcli con add type vlan con-name "VLAN30 Public" id 30 dev enp0s20f1 ip4 10.0.30.1/24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment