Before appending these values you must make sure to remove previous values:

    sed -i -e '/^COREOS_PUBLIC_IPV4=/d' \
        -e '/^COREOS_PRIVATE_IPV4=/d' \
        "${ENV}"