If we don't know where our scripts are, we have much deeper issues, but still not insurmountable.
$ sed -i 's/fgrep/grep\ -F/' $(grep -rw '/' -e 'fgrep')
(or something)
I don't manage docker images, but surely there must be a way to do something as simple as replace a file in one image,[1] and if that can be done, doing so in all images is just one clever step away.
And that doesn't even open the can of worms relating to quoting...