Running a script before absolutely everything

init is not the first action to run on a WordPress install. Here is a basic rundown of a typical stack order.

https://codex.wordpress.org/Plugin_API/Action_Reference

Try hooking into `muplugins_loaded’. I don’t believe it is conditional, so it should run every time.

https://codex.wordpress.org/Plugin_API/Action_Reference/muplugins_loaded

<?php
  add_action( 'muplugins_loaded', 'my_script' );

  function my_script() {
    // my script here
  }