how to insert a line of code in a specified code block with commands such as sed
, awk
, and so on.
suppose you have a file hello.php
, with the following contents:
piplin package, modify the app/Providers/AppServiceProvider.php
file, and add \ URL::forceScheme ("https") to the code block of the method function boot ()
;
to enable https. The container itself is a php network server, and php components are already installed, so using php to do this is a better solution in this case.