<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _get_user_data(self):
 """ Return formatted bash script string. The public ssh key is added by cloud init to the instance based on the ssh user and private key file. """

        key = ipa_utils.generate_public_ssh_key(
            self.ssh_private_key_file
        ).decode()
        script = BASH_SSH_SCRIPT.format(user=self.ssh_user, key=key)
        return script