| From: | Alex Aquino <alexaquino(at)gmail(dot)com> |
|---|---|
| To: | Jeremy Schneider <schneider(at)ardentperf(dot)com> |
| Cc: | Rashmi V Bharadwaj <rvbharad(at)in(dot)ibm(dot)com>, pgsql-general(at)postgresql(dot)org |
| Subject: | Re: PostgreSQL on Amazon RDS |
| Date: | 2019-05-18 22:33:01 |
| Message-ID: | CABxei-0y3VFfEjgFm1wcKostVgA+7oKTKguFad=z5EVi4aniPg@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Jeremy Schneider - Thanks for that psqlrc file. Pretty informative. :-)
On Wed, May 8, 2019 at 11:55 AM Jeremy Schneider <schneider(at)ardentperf(dot)com>
wrote:
> On 5/6/19 23:27, Rashmi V Bharadwaj wrote:
> > Is there a SQL query or a database parameter setting that I can use from
> > an external application to determine if the PostgreSQL database is on
> > cloud (like on Amazon RDS or IBM cloud) or on a non-cloud on-prem
> > environment?
>
> Here's my psqlrc file which has pretty solid logic for detecting between
> Community PostgreSQL, RDS PostgreSQL and Aurora PostgreSQL. Note that
> it just assumes "community/oss" as a default if it doesn't detect the
> other two. Should be easy enough to add detection of other hosted
> environments into the query with the "priority" column (as long as
> there's a reliable way to detect).
>
> https://gist.github.com/ardentperf/52bd418e44b1be26d7b63af21331cece
>
> This psqlrc also detects read-write versus read-only (e.g. hot standby),
> and the usual username/database/superuser info and builds everything
> into the prompt in a way that suits me.
>
> -Jeremy
>
> --
> http://about.me/jeremy_schneider
>
>
>
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Peter J. Holzer | 2019-05-18 22:39:52 | Re: bigint out of range |
| Previous Message | Ron | 2019-05-18 22:14:59 | Re: bigint out of range |