bottle: prevent bottling formula outside core or taps
bottle: prevent bottling formula outside core or taps

Closes #47233.

Homebrew/homebrew,BrewTestBot/homebrew,mactkg/homebrew,cscetbon/homebrew,jamer/homebrew,tutumcloud/homebrew,thinker0/homebrew,tutumcloud/homebrew,arnested/homebrew,gnubila-france/linuxbrew,hyuni/homebrew,cprecioso/homebrew,sjackman/linuxbrew,dongcarl/homebrew,Linuxbrew/linuxbrew,jarrettmeyer/homebrew,slyphon/homebrew,vigo/homebrew,nandub/homebrew,cscetbon/homebrew,Red54/homebrew,reelsense/linuxbrew,cprecioso/homebrew,yumitsu/homebrew,drbenmorgan/linuxbrew,ralic/homebrew,joshfriend/homebrew,SuperNEMO-DBD/cadfaelbrew,ento/homebrew,Homebrew/homebrew,danieroux/homebrew,marcwebbie/homebrew,skinny-framework/homebrew,sjackman/linuxbrew,booi/homebrew,jsjohnst/homebrew,thinker0/homebrew,blogabe/homebrew,Chilledheart/homebrew,getgauge/homebrew,johanhammar/homebrew,menivaitsi/homebrew,danieroux/homebrew,kodabb/homebrew,polishgeeks/homebrew,adamliter/homebrew,zchee/homebrew,SteveClement/homebrew,iandennismiller/homebrew,retrography/homebrew,elgertam/homebrew,reelsense/homebrew,brunchboy/homebrew,recruit-tech/homebrew,dunn/homebrew,ybott/homebrew,reelsense/linuxbrew,totalvoidness/homebrew,ryanfb/homebrew,gawbul/homebrew,OJFord/homebrew,3van/homebrew,josa42/homebrew,dutchcoders/homebrew,hanxue/homebrew,elgertam/homebrew,alebcay/homebrew,keith/homebrew,iandennismiller/homebrew,SteveClement/homebrew,vigo/homebrew,nelstrom/homebrew,eighthave/homebrew,treyharris/homebrew,totalvoidness/homebrew,OJFord/homebrew,Asuranceturix/homebrew,jab/homebrew,georgschoelly/homebrew,knpwrs/homebrew,polishgeeks/homebrew,jab/homebrew,zhipeng-jia/homebrew,DoomHammer/linuxbrew,feelpp/homebrew,theeternalsw0rd/homebrew,SteveClement/homebrew,scorphus/homebrew,booi/homebrew,MoSal/homebrew,sjackman/linuxbrew,afh/homebrew,princeofdarkness76/homebrew,utzig/homebrew,davydden/linuxbrew,hongkongkiwi/homebrew,scorphus/homebrew,gicmo/homebrew,dunn/homebrew,tschoonj/homebrew,teslamint/homebrew,kevinastone/homebrew,pcottle/homebrew,3van/homebrew,liamstask/homebrew,dickeyxxx/homebrew,gicmo/homebrew,ybott/homebrew,gawbul/homebrew,cosmo0920/homebrew,3van/homebrew,tutumcloud/homebrew,gicmo/homebrew,sferik/homebrew,ExtremeMan/homebrew,base10/homebrew,ExtremeMan/homebrew,skatsuta/homebrew,mkrapp/homebrew,SuperNEMO-DBD/cadfaelbrew,arnested/homebrew,ear/homebrew,jiashuw/homebrew,tschoonj/homebrew,iandennismiller/homebrew,keith/homebrew,johanhammar/homebrew,mmizutani/homebrew,mkrapp/homebrew,tutumcloud/homebrew,ilovezfs/homebrew,haihappen/homebrew,yumitsu/homebrew,bukzor/linuxbrew,scpeters/homebrew,ralic/homebrew,BrewTestBot/homebrew,nelstrom/homebrew,sferik/homebrew,zchee/homebrew,frodeaa/homebrew,vigo/homebrew,hyuni/homebrew,utzig/homebrew,benjaminfrank/homebrew,cprecioso/homebrew,deorth/homebrew,chadcatlett/homebrew,zchee/homebrew,mactkg/homebrew,manphiz/homebrew,zhipeng-jia/homebrew,SteveClement/homebrew,Red54/homebrew,galaxy001/homebrew,decors/homebrew,LinusU/homebrew,jconley/homebrew,Linuxbrew/linuxbrew,lrascao/homebrew,benjaminfrank/homebrew,hongkongkiwi/homebrew,kenips/homebrew,hongkongkiwi/homebrew,manphiz/homebrew,jconley/homebrew,knpwrs/homebrew,MartinDelille/homebrew,TaylorMonacelli/homebrew,chadcatlett/homebrew,jsjohnst/homebrew,apjanke/homebrew,deorth/homebrew,Asuranceturix/homebrew,ryanfb/homebrew,hyuni/homebrew,drewwells/homebrew,sometimesfood/homebrew,afh/homebrew,feelpp/homebrew,mactkg/homebrew,quantumsteve/homebrew,recruit-tech/homebrew,pdxdan/homebrew,booi/homebrew,royhodgman/homebrew,influxdata/homebrew,getgauge/homebrew,haihappen/homebrew,hakamadare/homebrew,brunchboy/homebrew,AlexejK/homebrew,3van/homebrew,dalanmiller/homebrew,Homebrew/homebrew,OJFord/homebrew,afh/homebrew,miketheman/homebrew,scorphus/homebrew,mactkg/homebrew,elyscape/homebrew,nandub/homebrew,optikfluffel/homebrew,jconley/homebrew,pcottle/homebrew,jarrettmeyer/homebrew,esamson/homebrew,emcrisostomo/homebrew,sjackman/linuxbrew,dickeyxxx/homebrew,brunchboy/homebrew,influxdata/homebrew,marcwebbie/homebrew,nandub/homebrew,TaylorMonacelli/homebrew,LinusU/homebrew,kodabb/homebrew,pdxdan/homebrew,joshfriend/homebrew,drewwells/homebrew,skatsuta/homebrew,dericed/homebrew,retrography/homebrew,dplarson/homebrew,marcwebbie/homebrew,DoomHammer/linuxbrew,recruit-tech/homebrew,theeternalsw0rd/homebrew,SuperNEMO-DBD/cadfaelbrew,dunn/homebrew,ablyler/homebrew,eighthave/homebrew,bigbes/homebrew,scorphus/homebrew,apjanke/homebrew,dgageot/homebrew,ento/homebrew,MartinDelille/homebrew,quantumsteve/homebrew,teslamint/homebrew,OJFord/homebrew,kodabb/homebrew,slyphon/homebrew,filcab/homebrew,iostat/homebrew2,ebouaziz/linuxbrew,osimola/homebrew,princeofdarkness76/homebrew,Linuxbrew/linuxbrew,arnested/homebrew,gicmo/homebrew,dongcarl/homebrew,jiashuw/homebrew,osimola/homebrew,princeofdarkness76/homebrew,optikfluffel/homebrew,ybott/homebrew,theeternalsw0rd/homebrew,kenips/homebrew,mmizutani/homebrew,kodabb/homebrew,skatsuta/homebrew,sakra/homebrew,influxdb/homebrew,pcottle/homebrew,youtux/homebrew,Angeldude/linuxbrew,saketkc/linuxbrew,dutchcoders/homebrew,emcrisostomo/homebrew,ilovezfs/homebrew,ryanfb/homebrew,davydden/linuxbrew,muellermartin/homebrew,dgageot/homebrew,haihappen/homebrew,MoSal/homebrew,feelpp/homebrew,MartinDelille/homebrew,sakra/homebrew,mmizutani/homebrew,kevinastone/homebrew,dgageot/homebrew,theeternalsw0rd/homebrew,michaKFromParis/homebrew-sparks,sometimesfood/homebrew,ento/homebrew,hakamadare/homebrew,osimola/homebrew,drewwells/homebrew,influxdata/homebrew,MartinDelille/homebrew,elgertam/homebrew,eighthave/homebrew,Chilledheart/homebrew,johanhammar/homebrew,menivaitsi/homebrew,yazuuchi/homebrew,polishgeeks/homebrew,miketheman/homebrew,cprecioso/homebrew,dericed/homebrew,georgschoelly/homebrew,Angeldude/linuxbrew,dongcarl/homebrew,filcab/homebrew,jamer/homebrew,yazuuchi/homebrew,Asuranceturix/homebrew,teslamint/homebrew,marcwebbie/homebrew,sakra/homebrew,chadcatlett/homebrew,galaxy001/homebrew,jamer/homebrew,Red54/homebrew,drbenmorgan/linuxbrew,retrography/homebrew,jiashuw/homebrew,esamson/homebrew,saketkc/linuxbrew,Linuxbrew/linuxbrew,emcrisostomo/homebrew,polishgeeks/homebrew,dplarson/homebrew,galaxy001/homebrew,base10/homebrew,keith/homebrew,sferik/homebrew,joshfriend/homebrew,LinusU/homebrew,youtux/homebrew,sferik/homebrew,jarrettmeyer/homebrew,princeofdarkness76/homebrew,dutchcoders/homebrew,ilovezfs/homebrew,treyharris/homebrew,danieroux/homebrew,ilovezfs/homebrew,pcottle/homebrew,deorth/homebrew,kevinastone/homebrew,jab/homebrew,dutchcoders/homebrew,liamstask/homebrew,knpwrs/homebrew,muellermartin/homebrew,decors/homebrew,alebcay/homebrew,ralic/homebrew,saketkc/linuxbrew,eighthave/homebrew,dalanmiller/homebrew,TaylorMonacelli/homebrew,ybott/homebrew,skatsuta/homebrew,influxdb/homebrew,iostat/homebrew2,BrewTestBot/homebrew,TaylorMonacelli/homebrew,hakamadare/homebrew,scpeters/homebrew,benjaminfrank/homebrew,sometimesfood/homebrew,nelstrom/homebrew,ablyler/homebrew,bukzor/linuxbrew,iostat/homebrew2,Red54/homebrew,kenips/homebrew,josa42/homebrew,bukzor/linuxbrew,Angeldude/linuxbrew,dplarson/homebrew,mmizutani/homebrew,Homebrew/linuxbrew,dplarson/homebrew,MoSal/homebrew,jconley/homebrew,galaxy001/homebrew,yazuuchi/homebrew,AlexejK/homebrew,michaKFromParis/homebrew-sparks,jarrettmeyer/homebrew,blogabe/homebrew,danieroux/homebrew,davydden/linuxbrew,slyphon/homebrew,Homebrew/linuxbrew,dalanmiller/homebrew,ebouaziz/linuxbrew,bigbes/homebrew,scpeters/homebrew,influxdb/homebrew,reelsense/homebrew,mobileoverlord/homebrew-1,Asuranceturix/homebrew,royhodgman/homebrew,SteveClement/homebrew,sakra/homebrew,treyharris/homebrew,slyphon/homebrew,menivaitsi/homebrew,emcrisostomo/homebrew,optikfluffel/homebrew,nelstrom/homebrew,decors/homebrew,elyscape/homebrew,sometimesfood/homebrew,liamstask/homebrew,gnubila-france/linuxbrew,elgertam/homebrew,ear/homebrew,Homebrew/linuxbrew,utzig/homebrew,redpen-cc/homebrew,miketheman/homebrew,tschoonj/homebrew,bigbes/homebrew,redpen-cc/homebrew,royhodgman/homebrew,DoomHammer/linuxbrew,dgageot/homebrew,getgauge/homebrew,youtux/homebrew,georgschoelly/homebrew,josa42/homebrew,filcab/homebrew,reelsense/homebrew,quantumsteve/homebrew,manphiz/homebrew,Asuranceturix/homebrew,skinny-framework/homebrew,afh/homebrew,jsjohnst/homebrew,AlexejK/homebrew,totalvoidness/homebrew,pcottle/homebrew,dickeyxxx/homebrew,pdxdan/homebrew,hanxue/homebrew,elyscape/homebrew,kenips/homebrew,ryanfb/homebrew,mobileoverlord/homebrew-1,thinker0/homebrew,miketheman/homebrew,DoomHammer/linuxbrew,dalanmiller/homebrew,haihappen/homebrew,frodeaa/homebrew,frodeaa/homebrew,cosmo0920/homebrew,ExtremeMan/homebrew,mobileoverlord/homebrew-1,AlexejK/homebrew,menivaitsi/homebrew,ebouaziz/linuxbrew,pdxdan/homebrew,scpeters/homebrew,michaKFromParis/homebrew-sparks,skinny-framework/homebrew,benjaminfrank/homebrew,ExtremeMan/homebrew,esamson/homebrew,osimola/homebrew,Homebrew/homebrew,hanxue/homebrew,feelpp/homebrew,jab/homebrew,totalvoidness/homebrew,gawbul/homebrew,bigbes/homebrew,dericed/homebrew,tschoonj/homebrew,blogabe/homebrew,LinusU/homebrew,esamson/homebrew,hyuni/homebrew,yazuuchi/homebrew,apjanke/homebrew,gnubila-france/linuxbrew,recruit-tech/homebrew,skinny-framework/homebrew,johanhammar/homebrew,cosmo0920/homebrew,base10/homebrew,apjanke/homebrew,zhipeng-jia/homebrew,dericed/homebrew,ralic/homebrew,adamliter/homebrew,base10/homebrew,MoSal/homebrew,keith/homebrew,blogabe/homebrew,davydden/linuxbrew,adamliter/homebrew,alebcay/homebrew,muellermartin/homebrew,nandub/homebrew,optikfluffel/homebrew,hongkongkiwi/homebrew,teslamint/homebrew,manphiz/homebrew,drbenmorgan/linuxbrew,jiashuw/homebrew,utzig/homebrew,brunchboy/homebrew,ear/homebrew,elyscape/homebrew,reelsense/homebrew,youtux/homebrew,jamer/homebrew,Homebrew/linuxbrew,reelsense/linuxbrew,iostat/homebrew2,lrascao/homebrew,hanxue/homebrew,cosmo0920/homebrew,mkrapp/homebrew,jsjohnst/homebrew,BrewTestBot/homebrew,georgschoelly/homebrew,adamliter/homebrew,iandennismiller/homebrew,muellermartin/homebrew,SuperNEMO-DBD/cadfaelbrew,dickeyxxx/homebrew,ento/homebrew,redpen-cc/homebrew,getgauge/homebrew,arnested/homebrew,ebouaziz/linuxbrew,hakamadare/homebrew,decors/homebrew,lrascao/homebrew,mobileoverlord/homebrew-1,thinker0/homebrew,Chilledheart/homebrew,zhipeng-jia/homebrew,ear/homebrew,drewwells/homebrew,reelsense/linuxbrew,zchee/homebrew,liamstask/homebrew,ablyler/homebrew,treyharris/homebrew,saketkc/linuxbrew,influxdb/homebrew,redpen-cc/homebrew,alebcay/homebrew,Chilledheart/homebrew,quantumsteve/homebrew,influxdata/homebrew,retrography/homebrew,yumitsu/homebrew,dongcarl/homebrew,bukzor/linuxbrew,royhodgman/homebrew,kevinastone/homebrew,filcab/homebrew,drbenmorgan/linuxbrew,cscetbon/homebrew,vigo/homebrew,dunn/homebrew,ablyler/homebrew,knpwrs/homebrew,frodeaa/homebrew,gnubila-france/linuxbrew,Angeldude/linuxbrew