Tychobra / polished

Authentication and Administration for Shiny apps
https://polished.tech
Other
233 stars 36 forks source link

Problem to deploy Golem App to Polished #216

Closed agronomofiorentini closed 1 year ago

agronomofiorentini commented 1 year ago

Dear creators, I would like to deploy a golem app using your framework and i have done the following steps:

  1. Build a golem app

  2. Modify the run_app.R as follow

    #' Run the Shiny Application
    #'
    #' @param ... A series of options to be used inside the app.
    #'
    #' @export
    #' @importFrom shiny shinyApp
    #' @importFrom golem with_golem_options
    #' @importFrom polished global_sessions_config secure_ui secure_server
    run_app <- function(
    ...
    ) {
    
    polished::polished_config(app_name = "DropDetector",
                            api_key = Sys.getenv("polished_api"),
                            is_invite_required = FALSE,
                            is_email_verification_required = TRUE)
    
    my_custom_sign_in_page <- polished::sign_in_ui_default(color = "#006CB5",
                                                         company_name = "AFS - DropDetector",
                                                         logo_top = tags$img(src = "https://i.ibb.co/NZ8qZsk/111111.png",
                                                                             alt = "Automatic Farm Solution Logo",
                                                                             style = "width: 200px; margin-top: 15px; margin-bottom: 15px;"),
                                                         logo_bottom = tags$img(src = "https://i.ibb.co/sgDNtwD/a.png",
                                                                                alt = "Automatic Farm Solution Logo",
                                                                                style = "width: 200px; margin-bottom: 15px; padding-top: 15px;"),
                                                         icon_href = "https://i.ibb.co/NZ8qZsk/111111.png",
                                                         background_image = "https://i.ibb.co/7t6gSX9/agriculture-1867212-1280.jpg")
    
    with_golem_options(
    app = shinyApp(
      ui = polished::secure_ui(app_ui,
                               sign_in_page_ui = my_custom_sign_in_page),
      server = polished::secure_server(app_server)
    ),
    golem_opts = list()
    )
    }
  3. Build golem app and test it locally

    
    devtools::build()

devtools::install()

and everything is working, infact the DropDetector App can be loaded as package by using `library(DropDetector)`

4. Deploy to polished by using the following code 

polished::deploy_app( app_dir = ".", golem_package_name ="DropDetector", api_key = "apikey", region = "europe-west8", ram_gb = 16, app_name ="DropDetector" )


but this command give me the following error

Creating app bundle...Error: CRAN or GitHub info for DropDetector not found. Other packages repos are not supported.



how can i solve this and use the polished service?
agronomofiorentini commented 1 year ago

Dear Polished, I have created a github repository, but still the problem persist.

""" https://github.com/agronomofiorentini/DropDetector """