# AutomationTool was unable to run successfully. Exited with code: 1 - gradlew\\" :app:bundleRelease"

**URL:** <https://forums.unrealengine.com/t/automationtool-was-unable-to-run-successfully-exited-with-code-1-gradlew-bundlerelease/571781>\
**Category:** Platform & Builds\
**Tags:** unreal-engine, UE5-0, Android, question\
**Created:** [June 1, 2022, 6:07pm UTC](https://forums.unrealengine.com/t/automationtool-was-unable-to-run-successfully-exited-with-code-1-gradlew-bundlerelease/571781 "2022-06-01T18:07:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![srhrs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@srhrs](https://forums.unrealengine.com/u/srhrs)\
**Post date:** [June 1, 2022, 6:07pm UTC](https://forums.unrealengine.com/t/automationtool-was-unable-to-run-successfully-exited-with-code-1-gradlew-bundlerelease/571781/1 "2022-06-01T18:07:23Z")

</div>

Hello,  
I’m having this problem with Android packaging:

> UATHelper: Packaging (Android (ASTC)): ERROR: /bin/sh failed with args -c “"/Users/SRH/Documents/Unreal Projects/Packed 5.0/Intermediate/Android/gradle/gradlew" :app:bundleRelease”
> 
> UATHelper: Packaging (Android (ASTC)): RunUAT ERROR: AutomationTool was unable to run successfully. Exited with code: 1
> 
> PackagingResults: Error: Unknown Error

These are my SDK settings:

 ![Schermata 2022-06-01 alle 19.52.49](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/3/1/031f2c13513af4cad48561189fc49f9099caa60e.png)

I’m using a Macbook Pro, macOS Monterey 12.4

I tried different methods but none worked in my case…

I hope someone can help me 😅

Thank you!

---

<div class="post-metadata">

**Author:** ![srhrs](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@srhrs](https://forums.unrealengine.com/u/srhrs)\
**Post date:** [August 14, 2022, 2:07pm UTC](https://forums.unrealengine.com/t/automationtool-was-unable-to-run-successfully-exited-with-code-1-gradlew-bundlerelease/571781/2 "2022-08-14T14:07:52Z")

</div>

SOLVED  
The problem was related to the keystore, I was compiling the part Distribution Signing wrong.

I had followed the official guide on how to create a key, this one: [https://docs.unrealengine.com/4.27/en-US/SharingAndReleasing/Mobile/Android/DistributionSigning/](https://docs.unrealengine.com/4.27/en-US/SharingAndReleasing/Mobile/Android/DistributionSigning/)

…but, instead of writing as alias “MyKey” as shown in the code, I put one of my own; this was because I had followed the guide without understanding what I was doing.

The code is:

```auto
keytool -genkey -v -keystore ExampleKey.keystore -alias MyKey -keyalg RSA -keysize 2048 -validity 10000

```

**ExampleKey.keystore** is the file key name, it must be written as KeyStore in Distribution Signing section  
**MyKey** is the alias name, it must be written as Key Alias in Distribution Signing section

 ![Schermata 2022-08-14 alle 15.58.36](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/d/4/6d4611503198a0c52cea5261b39b78eabbe3a678.png)

Both names can be changed at will as long as they fit in the quoted code, this is the point.

I know it may seem silly to explain something that is already explained in both the guide and the section Distribution Signing but I think it can be of help to other beginners like me.

I took months to understand it, I hope others take less 🤣
