···179179180180 # Remove the old /var/setuid-wrappers path from the system...
181181 #
182182- # TODO: this is only necessary for ugprades 16.09 => 17.x;
182182+ # TODO: this is only necessary for upgrades 16.09 => 17.x;
183183 # this conditional removal block needs to be removed after
184184 # the release.
185185 if [ -d /var/setuid-wrappers ]; then
186186 rm -rf /var/setuid-wrappers
187187+ ln -s /run/wrappers/bin /var/setuid-wrappers
187188 fi
188189189190 # Remove the old /run/setuid-wrappers-dir path from the
190191 # system as well...
191192 #
192192- # TODO: this is only necessary for ugprades 16.09 => 17.x;
193193+ # TODO: this is only necessary for upgrades 16.09 => 17.x;
193194 # this conditional removal block needs to be removed after
194195 # the release.
195196 if [ -d /run/setuid-wrapper-dirs ]; then
196197 rm -rf /run/setuid-wrapper-dirs
198198+ ln -s /run/wrappers/bin /run/setuid-wrapper-dirs
199199+ fi
200200+201201+ # TODO: this is only necessary for upgrades 16.09 => 17.x;
202202+ # this conditional removal block needs to be removed after
203203+ # the release.
204204+ if readlink -f /run/booted-system | grep nixos-17 > /dev/null; then
205205+ rm -rf /run/setuid-wrapper-dirs
206206+ rm -rf /var/setuid-wrappers
197207 fi
198208199209 # We want to place the tmpdirs for the wrappers to the parent dir.