SSL peer certificate or SSH remote key was not OK

Edit: Solved for me

I saw this error message from the log after deploying my app. The app was working fine locally but having issue accessing the URL via, throwing error message "SSL peer certificate or SSH remote key was not OK"

The solution that works for me is to change the url from https to http.

Repex (before changing to http) :


ui <- fluidPage(
  actionButton("submit", "Submit"),

server <- function(input, output, session) {
  observeEvent(input$submit, {
    url <- ""
    h1 <- GET(url=url, verbose(), config(cainfo="cacert.pem"))
    h2 <- content(h1, as="text")
    df <- fromJSON(h2)
    output$table <- renderDataTable({df})

shinyApp(ui, server)
1 Like