How do I set up custom permissive relationships?
Yes, that checkbox must be checked. (The one reflecting the specific "direction" you wish.

I don't think you can configure this to occur automatically, however since you have custom code, it should be possible to add the permission automatically using an API call (the parameter name I believe is is_permission_a_b or is_permission_b_a).

Here's an API call:

$result = civicrm_api3('Relationship', 'create', array(
  'sequential' =&gt; 1,
  'contact_id_a' =&gt; "",
  'contact_id_b' =&gt; "",
  'relationship_type_id' =&gt; "",
  'is_permission_a_b' =&gt; "",
  'is_permission_b_a' =&gt; "",
));