On Mon, January 22, 2018 2:36 am, Raimo Niskanen wrote: > On Fri, Jan 19, 2018 at 10:47:15AM -0500, trondd wrote: >> On Fri, January 19, 2018 4:29 am, Raimo Niskanen wrote: >> > Hello list! >> > >> > I have some machines behind a squid proxy and have set the http_proxy >> and >> > ftp_proxy environment variables both in /etc/profile and in >> > /etc/login.conf >> > for the default login class. This works well. >> > >> > But after an upgrade when rc.firsttime calls fw_update and checks for >> > binary patches the proxy is not used, so I have to wait for that to >> time >> > out or break it with Ctrl-C and call fw_update manually. >> > >> > So I just wonder if anybody have an idea of how to set the http_proxy >> and >> > ftp_proxy environment variables so they are picked up by rc.firsttime? >> > >> > Best regards >> > -- >> > >> > / Raimo Niskanen, Erlang/OTP, Ericsson AB >> > >> >> I submitted a patch for this: >> https://marc.info/?l=openbsd-tech&m=151260860105270&w=2 > > That sure looks like an improvement! But should maybe $http_proxy be > placed between single quotes? > > Unfortunately I fetch the sets into /var/OpenBSD/`machine` and verify them > before rebooting into /bsd62.rd, so it would not work for me... > >> >> In the meantime, before reboot, you can edit the rc.firstime script >> after >> installation. > > I'll try that trick next time. Thank you! > >> >> Tim. > > -- > > / Raimo Niskanen, Erlang/OTP, Ericsson AB >
Ah, I see. Yeah, I only acconted for the obvious case when a net install was done. Having thought about it again, an easier solution will be to write your http_proxy export to /etc/rc.firsttime before rebooting into bsd.rd. If you have your update process scripted already, it's an easy additional line. The installer only appends commands so anything you have in rc.firsttime will be preserved. Tim.