Security for R Shiny App secrets on shinyapps.io - r

I am using persistent data storage with a deployed app on shinyapps.io. I am reading and writing to an external SQL db. This app will be open to public, but data saved will be private.
What is the best/most secure way to store the private api keys for the db on the shinyapps.io server?
Config file?
.renviron?

Related

Use Firebase-functions-emulator with remote firebase services

Can I connect the firebase-functions-emulator with the remote authentication and firestore service? Currently it is connecting only to the other local emulators. I don't want to setup my db locally.
It's not possible to have the local Cloud Functions emulator respond to (or "trigger" on) events in a production database. You have to deploy your functions in order for them to execute in response to change in the cloud-hosted database. The local functions emulator only responds to changes in the locally emulated database.
Refer the following to understand how to Connect your app to the Realtime Database Emulator
Check a similar example here.

How to share Database connection pool between shiny apps under ShinyProxy

In my practice, many shiny apps needs to access Postgresql DB which installed on host.
I use pool package to get connection pool of Postgresql, and set it to global variable shared for other apps.
But every new user trigger app, it would get new connection of Postgresql.
I'm afraid Postgresql would crash down when too much concurrent users use shiny apps.
Is any solution for this secenario?
pool package introduction as bellowing url.
https://shiny.rstudio.com/articles/pool-basics.html
Thanks a lot.

Firebase Firestore not showing documents created by my flutter application

I was able to configure the Firestore database in Firebase with my flutter app and also create and read documents from my collection but when I go to Firestore console I don't see the created data, also when I creat data manually I am unable to see it in my application.
I am using the test mode which means any user can read or write.
I hope someone can help me with this puzzle.
Thanks!!!
It sounds like the device/emulator that you are running on is not connected to the internet, or at least not to the Firestore servers. In that case, the client writes all local changes into a local database, waiting to send them to the server when it gets a connection. So the local app will work, but won't be able to synchronize its local cache with the database servers.
You might want to check the connection on your device, and any proxies that might exist between your app and the Firestore servers.

How do I view the contents of my "default" type Cloud SQL database in AppMaker?

I created a new AppMaker app and selected the "default" (as opposed to "custom") Cloud SQL database backend.
While I'm prototyping my app, I'd like to be able to inspect the contents of my database periodically as an admin to debug issues. With a custom Cloud SQL database this is easy because you can acess a custom Cloud SQL database from the cloud console, but I don't see how to manually query a default Cloud SQL database.
I know that I can export my database to a Google Sheet, but that's inconvenient to do frequently.
How do I inspect the contents of my AppMaker default Cloud SQL database for debugging (eg. via a SQL command line, UI tool, etc)?
I believe it would be the same as with the custom one. The documentation explains:
A G Suite administrator can set up a Google Cloud SQL instance that is shared among App Maker apps in an organization. When this is enabled, a new database is automatically created for your app when you add at least one Cloud SQL data model. Choose this option if your app needs a database that is easy to use and requires no set up.
This means that you had set up correctly the instance information in the G Suite Admin console:
So to connect to your SQL instance, you just need to follow the instructions here. Then simply use the instance connection name where required. You will also need the database name and you can get that from the appsettings or deployment settings in appmaker.
For the preview mode it will be in the app settings. For any deployed version, it will be in the deployment settings:

Access Sqlite database in background while data protection is on for app

Can we access the Sqlite database in background while data protection is on for the app. If the data protection is on for the app then the file system is not accessible. Can app write to database in that case?
Sqlite database is not accessible when complete data protection is on. From apple web site
While the user’s device is locked, protected files are inaccessible even to the app that created them.

Resources