#Setting up github functions, signing key cannot be empty.

14 messages · Page 1 of 1 (latest)

lethal matrix
#

self hosted version 1.5.5
The logs:
[Error] Timestamp: 2024-05-21T09:05:48+00:00
[Error] Method: GET
[Error] URL: /v1/vcs/github/callback
[Error] Type: Ahc\Jwt\JWTException
[Error] Message: Signing key cannot be empty
[Error] File: /usr/src/code/vendor/adhocore/jwt/src/ValidatesJWT.php
[Error] Line: 34

My open ssl key is not empty
github private key has been set

Whenever I create a new function it takes me to the github app settings page

Any thoughts insight would be greatly appreciated.

merry flower
lethal matrix
#

This is the format I currently have, it it correct? _APP_VCS_GITHUB_PRIVATE_KEY="-----BEGIN RSA PRIVATE KEY-----\n***\n-----END RSA PRIVATE KEY-----"

merry flower
lethal matrix
#

without

#

it shows it as

  • _APP_VCS_GITHUB_PRIVATE_KEY=-----BEGIN RSA PRIVATE KEY-----

-----END RSA PRIVATE KEY-----

merry flower
#

can you try runnign this?

CODE='
if (openssl_pkey_get_private(getenv("_APP_VCS_GITHUB_PRIVATE_KEY")) === false) {
    echo "Invalid Private Key\n";
    exit(1);
} else {
    echo "Valid Private Key\n";
    exit(0);
}'

docker compose exec appwrite php -r "$CODE"
lethal matrix
#

I got invalid private key

#

so it is how I am setting it?

#

It would be fine to show the formatting with a key that has been deleted correct?

merry flower