Unable to create a new app on fresh openBalena server

I’ve setup an openBalena server following the instructions provided here. The containers are up and I’m able to login, but I’m unable to create or view apps. When I try to create an app, I’m seeing the following error.

BalenaRequestError: Request error: <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Error</title>
</head>
<body>
<pre>Cannot GET /v6/organization</pre>
</body>
</html>

I’m trying to create a qemux86-64 app. Please help me understand what is going wrong and how to resolve this

Hello, what version of the CLI are you running? (you can run balena --version to find out)

I’m using 12.14.1

Im trying to verify if this is the case with the relevant team members, but I suspect there might be some incompatibilities with open-balena introduced in version 12.14.1 of the CLI. Could you try to downgrade to 12.14.0 and check if you still have the same issue? You can download that version from https://github.com/balena-io/balena-cli/releases/tag/v12.14.0 of (assuming you have all the dependencies specified in https://github.com/balena-io/balena-cli/blob/master/INSTALL.md#npm-installation) with npm i -g balena-cli@12.14.0 --production --unsafe-perm

Thanks, downgrading seems to have resolved that issue for me.

However, I’ve noticed that the logs of cert_provider container are showing an error message

[Error] ACTIVE variable is not enabled. Value should be “true” or “yes” to continue.
[Error] Unable to continue due to misconfiguration. See errors above. [Stopping]

Is this something I should worry about?

Hello Anil,
Glad downgrading did the trick and the problem is resolved.
Regarding the cert_provider container logs you posted. This is expected behaviour as the ACTIVE variable is for toggling ACME certification on and off in the Openbalena server. If your Openbalena server is working fine and you don’t need ACME certification then you can disregard this error. Thanks!

References
[1] https://github.com/balena-io/open-balena/blob/d70c2177ffa8f0d15449f1a2c10d31d7322a0cc8/compose/services.yml#L185
[2] https://github.com/balena-io/open-balena/blob/c58ee37f175a15747fa27d714e717d2131289c20/src/cert-provider/cert-provider.sh#L80

Heads up…

In the getting started guide of openBalena says to install cli version 12.2.2 which fails with this error when trying to create a new app.
Document should be updated to ask for version 12.14.0 which works well.

In the getting started guide of openBalena says to install cli version 12.2.2 which fails with this error when trying to create a new app.

@rbarbero, do you mean that CLI v12.2.2 causes the following error to appear in the logs of cert_provider container, whereas CLI v12.14.0 avoids it?

[Error] ACTIVE variable is not enabled. Value should be “true” or “yes” to continue.

If so, is it still reproducible? At the moment I don’t see how CLI versions 12.2.2 and 12.14.0 differ in relation to this specific error, but perhaps I have not dug deep enough. Or did you mean a different error?

openBalena’s Getting Started guide recommends the CLI to be downgraded to version 12.2.2 because it is a version that is fully compatible with the current release of openBalena. “Fully compatible” meaning that all CLI commands should work. Newer CLI versions may offer partial support for the current release of openBalena, meaning that some CLI commands would work, but not all commands. The underlying cause/explanation is that the openBalena API is pending an update for compatibility with balena SDK v14 and v15 and with balena API’s /v6 HTTP endpoint, which are used by balenaCloud and by some CLI commands in more recent CLI versions. The following GitHub issues may be used for tracking / subscribing for notifications:

My apologies…

I was referring to the first error in the post

Cannot GET /v6/organization

It was a fresh openBalena installation, fresh client v 12.2.2

It works with 12.14.0 as stated above, but the documentation to install openBalena refers to 12.2.2

Cannot GET /v6/organization
It was a fresh openBalena installation, fresh client v 12.2.2

@rbarbero, I cannot reproduce this error with CLI v12.2.2, "app create" command. Looking at the code, as far as I can tell, this error should not be possible with CLI v12.2.2 because it does not use the /v6 endpoint. I have just setup a fresh installation of openBalena following the Getting Started guide, then I downloaded the standalone zip packages of CLI versions 12.2.2, 12.14.0 and 12.14.1 and the results were as follows:

$ ./balena-cli-12.2.2/balena app create test-rpi --type raspberrypi3
Application created: test-rpi (raspberrypi3, id 1)

$ ./balena-cli-12.14.0/balena app create test2 --type raspberrypi3
Application created: test2 (raspberrypi3, id 2)

$ ./balena-cli-12.14.1/balena app create test3 --type raspberrypi3
BalenaRequestError: Request error: <!DOCTYPE html>
...
<pre>Cannot GET /v6/organization</pre>
...

Perhaps something went wrong with the installation of CLI v12.2.2 on your local machine. Try using the standalone zip packages to rule out installation issues.

In my previous post, I explain the reason for the recommendation of downgrading to CLI v12.2.2, and that newer versions (such as v12.14.0) currently offer partial support for openBalena.

@pdcastro, I used, as you say, the standalone zip package…

I’ll try to reproduce next time I install openBalena

Thanks for your quick responses

Thanks Roberto that would be very helpful if you can reproduce.

A new version of openBalena was released yesterday that is compatible with the latest CLI and balenaOS versions and should reesolve the issue you were seeing.