The bitbucket-pipe-release pipe ignores SSH_KEY when pushing a tag
Asked by Edoardo Pirovano:

I'm in the process of trying to release a custom pipe using [this](https://bitbucket.org/atlassian/bitbucket-pipe-release/src/master/) automation that you provide, but I'm running into some issues. In particular, I've set the SSH_KEY variable to a base64 encoded key with the right permissions as outlined by the instructions, which is working well for letting the pipe push commits. It is not, however, letting it push new tags. I believe the issue is that the git-tag.sh script in that pipe doesn't actually use the SSH_KEY: only the git-commit.sh one does. I believe copying the logic over to that script (as I've done in [this](https://bitbucket.org/edopirovano/bitbucket-pipe-release/commits/b41664c3765a1a05ad86161fa2ab9afb554d6f26) commit on my fork: feel free to use it) would get things working again.


Answers:
author: Edoardo Pirovano
body: [@Oleksandr Kyrdan](/t5/user/viewprofilepage/user-id/2885705)I see you've commited to that repository recently. Is this something you would be able to help with? Many thanks!


author: Oday Rafeh
body: [@Edoardo Pirovano](/t5/user/viewprofilepage/user-id/5173082)

The issue you're facing is due to the **git-tag. sh** script not utilizing the **SSH_KEY**.

To resolve this, you can update the **git-tag. sh** script by incorporating the logic from the **git-commit. sh** script.

You can use the commit you've made on your fork as a reference.

The steps:

Clone the bitbucket-pipe-release repository.

<br />

Modify the **git-tag. sh** script to use the **SSH key**.

Copy the relevant logic from the **git-commit. sh** script.

<br />

Test your changes locally to ensure that the script is working correctly with the **SSH key**.

<br />

Commit your changes and push them to your fork.

comments: author: Edoardo Pirovano
body: Thanks [@Oday Rafeh](/t5/user/viewprofilepage/user-id/5172837) I'm aware this is an option. I was hoping someone with the right permissions might merge my fix into the main repository, though, to avoid me having to keep a fork up to date.


author: Oday Rafeh
body: Hi [@Edoardo Pirovano](/t5/user/viewprofilepage/user-id/5173082) ,

I understand that you would like to have your changes incorporated into the main repository instead of maintaining a separate fork.

In this case, the best course of action is to submit a **pull request (PR)** to the original repository with your proposed changes.

You can create a pull request:

* Make sure you have pushed your changes to your forked repository on Bitbucket.
* Go to the original repository of the bitbucket-pipe-release.
* Click on the "Pull requests" tab in the top menu.
* Click on the "Create a pull request" button.
* In the "Source" section, choose your forked repository and the branch containing your changes.
* In the "Destination" section, choose the original repository and the branch you want to merge your changes into (usually the main or master branch).
* Add a title and a description for your pull request, explaining the changes you've made and their purpose.
* Click "Create pull request. "

<br />

Once you've submitted the pull request, the repository maintainers will review your changes. If they find your changes beneficial and without conflicts, they may choose to merge your changes into the main repository.


author: Edoardo Pirovano
body: Thanks for the instructions, but I do not actually have the permissions to open a pull request on bitbucket-pipe-release: the open pull request button is greyed out.


author: Igor Stoyanov
body: [@Edoardo Pirovano](/t5/user/viewprofilepage/user-id/5173082) hi.

Since you already implemented this feature [here](https://bitbucket.org/edopirovano/bitbucket-pipe-release/commits/b41664c3765a1a05ad86161fa2ab9afb554d6f26), please follow the [contribution docs](https://bitbucket.org/atlassian/bitbucket-pipe-release/src/master/CONTRIBUTING.md) to suggest this feature. Please, use **Fork** (check the docks).  

You are welcome and thanks for contribution.  

Regards, Igor


Tags: bitbucket-cloud

bitbucket-pipelines

cloud