Jira and Bitbucket Server integration work by looking through your commit logs for comments that start with or contain any issue keys. See the following screenshot:

If the commit comment contains an issue key, the commits will be displayed in the Development issue panel of the issue.