Trying to deploy with builder, but getting exception

I have an IVY plus board. after a successful build I am trying to deploy the image to my device.

Here is my command:
torizoncore-builder deploy ./my-branch --remote-host 192.168.11.115 --remote-username my-uname --remote-password “My-pw”

I am getting the following exception:
An unexpected Exception occurred. Please provide the following stack trace to
the Toradex TorizonCore support team:

Traceback (most recent call last):
File “/builder/torizoncore-builder”, line 231, in
mainargs.func(mainargs)
File “/builder/tcbuilder/cli/deploy.py”, line 228, in do_deploy
do_deploy_ostree_remote(args)
File “/builder/tcbuilder/cli/deploy.py”, line 191, in do_deploy_ostree_remote
deploy_ostree_remote(storage_dir=args.storage_directory,
File “/builder/tcbuilder/cli/deploy.py”, line 184, in deploy_ostree_remote
dbe.deploy_ostree_remote(remote_host, remote_username, remote_password,
File “/builder/tcbuilder/backend/deploy.py”, line 455, in deploy_ostree_remote
ret, csumdeploy = srcrepo.resolve_rev(ref, False)
gi.repository.GLib.GError: g-io-error-quark: Invalid refspec ./my-branch (0)

I am not sure what is wrong, other than it doesn’t like my build. The “my-branch” directory is local. What am I doing wrong?

Thanks,
Steve

Hi, I’m the Toradex AI Assistant. The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello!

It seems you’re encountering an error because the deploy command requires an OSTree reference name rather than a directory path. Here’s how you can correctly use the deploy command:

To deploy directly to your board via SSH, use the following format:

$ torizoncore-builder deploy --remote-host 192.168.1.117 --remote-username torizon --remote-password torizon --reboot

If you’re deploying with a custom branch, make sure to specify the branch name instead of a directory path:

$ torizoncore-builder deploy custom-branch --remote-host 192.168.1.117 --remote-username torizon --remote-password torizon

The error message “Invalid refspec ./my-branch” suggests that a directory path is being used where an OSTree reference name is expected. To resolve this:

  1. Use the branch name you specified during the build process instead of a directory path.
  2. Ensure that you’ve properly merged your customizations using the union command before deploying.

Additionally, starting from TorizonCore Builder version 3.1.0, if both your username and password are “torizon”, you can omit these arguments.

I hope this helps! If you have any more questions, feel free to ask.

Best regards,
Toradex AI Assistant

In the past, we just had it make a directory and deployed from that. Looking at the tcbuild.yaml template I am not sure where to name a branch in the file.
I tried using the git commit hex file and passed that along. It worked. Now I get to try an overlay.

hi @EvetsMostel1


So did the answer from the bot solved your initial question?
Can you click the checkbox to mark the topic as solved?