blob: 6b31cac10b82b5148f26ffda6033556bdbf64c0e [file] [log] [blame]
Ivan Berezovskiyc46e7c02018-10-29 18:22:09 +04001#!/bin/sh -e
2#
3# rc.local
4#
5# This script is executed at the end of each multiuser runlevel.
6# Make sure that the script will "exit 0" on success or any other
7# value on error.
8#
9# In order to enable or disable this script just change the execution
10# bits.
11#
12# By default this script does nothing.
13
14if [ ! -f /tmp/bootstrap_interfaces ] && [ -d /srv/salt/reclass/nodes/_generated ]; then
15 sed -i "s/single_address:.*/single_address: $(hostname -I | cut -d ' ' -f 1)/g" /srv/salt/reclass/nodes/cfg01.*
16 touch /tmp/bootstrap_interfaces
17fi
18
19exit 0