def _post_build(neurodocker_dict, post_build):
    """ extra instructions for the nfm framework"""
    instr_list = list(neurodocker_dict['instructions'])
    for key, val in post_build.items():
        if key == 'miniconda':
            env_nm = None
            for i, el in enumerate(instr_list):
                if el[0] == 'miniconda':
                    env_nm = el[1]['create_env']
            if env_nm:
                miniconda_dict = {'use_env': env_nm}
            else:
                miniconda_dict = {'create_env': 'testkraken'}
            miniconda_dict.update(val)
            instr_list.append(('miniconda', miniconda_dict))
        else:
            instr_list.append((key, val))
    neurodocker_dict['instructions'] = tuple(instr_list)
    return neurodocker_dict
