-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integration must generate a public key #1080
Comments
@jqtruong can you show me how you're creating the |
i think i'm missing something, the |
The media type is built into the helper methods, how are you creating the |
payload = {
# The time that this JWT was issued, _i.e._ now.
iat: Time.now.to_i,
# How long is the JWT good for (in seconds)?
# Let's say it can be used for 10 minutes before it needs to be refreshed.
# TODO we don't actually cache this token, we regenerate a new one every time!
exp: Time.now.to_i + (10 * 60),
# Your GitHub App's identifier number, so GitHub knows who issued the JWT, and know what permissions
# this token has.
iss: APP_IDENTIFIER
}
# Cryptographically sign the JWT
jwt = JWT.encode(payload, PRIVATE_KEY, 'RS256') where PRIVATE_KEY is set by PRIVATE_KEY = OpenSSL::PKey::RSA.new(ENV['GITHUB_PRIVATE_KEY'].gsub('\n', "\n")) # convert newlines |
@jqtruong out of curiosity, why are you converting the newlines? |
:) i'm just following orders... i mean instructions steps from the guide in this section. |
oh i guess it is useless in this code since it's already been converted in the environment variable. |
actually, nvm, that is needed because of the step in the guide. step replaces do you have any new thoughts that might help me? i'm willing to try anything at this point... |
closing, user error. i needed to specify the |
@jqtruong I have found this issue right now, could you explain how you add |
|
Hello, i'm getting an error:
i am following this guide, and the error stems from this function call:
in the
authenticate_installation
.Do you know why that might be happening?
The text was updated successfully, but these errors were encountered: