Automating apt-get install?

Sorry for posting in the wrong area, but none of the areas seemed to match and this is most active area, by far. So, here goes...

I'm having trouble using the 'apt-get install chef' in an automated fashion. Partway through the execution of this command, it puts up a "Package configuration" dialog which wants to know the URL of the default server.

Is there a way to pre-set this to (say) localhost? More generally, where can I find information on these sorts of configuration options for Chef? Inquiring gnomes need to mine...

-r

Addendum #1

I drilled down to chef_13.8.7-3_all.deb > control.tar.xz > templates and found this sort of thing:

Type: string
Description: URL of Chef server:
...

but I don't see any provision for pre-setting the URL.