This repository has been archived by the owner on Jun 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Archivo de configuración de clientes de postgresql
- Loading branch information
1 parent
191d92c
commit f19efce
Showing
1 changed file
with
73 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
#+TITLE: PostgreSQL configuration files | ||
#+AUTHOR: Adolfo De Unánue | ||
#+EMAIL: [email protected] | ||
#+PROPERTY: header-args:shell :tangle no :comments org :results silent | ||
#+PROPERTY: header-args :results silent :eval no-export :comments org | ||
#+OPTIONS: num:nil toc:nil todo:nil tasks:nil tags:nil | ||
#+OPTIONS: skip:nil author:nil email:nil creator:nil timestamp:nil | ||
#+INFOJS_OPT: view:nil toc:nil ltoc:t mouse:underline buttons:0 path:http://orgmode.org/org-info.js | ||
|
||
|
||
Ambos archivos deben de ir en =$HOME= | ||
|
||
|
||
* Connection service file ( =.pg_service.conf= ) | ||
|
||
[[https://www.postgresql.org/docs/current/libpq-pgservice.html][Documentación]] | ||
|
||
Para conectarme con =psql= | ||
|
||
#+begin_src text :eval never | ||
psql service=ccd-db | ||
#+end_src | ||
|
||
#+begin_src text :tangle ~/.pg_service.conf | ||
|
||
#ccd | ||
[ccd] | ||
host=localhost | ||
port=5444 | ||
user=nanounanue | ||
dbname=postgres | ||
|
||
|
||
# ccd-itam | ||
[itam] | ||
host=localhost | ||
port=5444 | ||
user=nanounanue | ||
dbname=itam | ||
|
||
# ccd-amai | ||
[amai] | ||
host=localhost | ||
port=5444 | ||
user=nanounanue | ||
dbname=amai_2019 | ||
#+end_src | ||
|
||
|
||
* Passwords ( =.pgpass= ) | ||
|
||
[[https://www.postgresql.org/docs/current/libpq-pgpass.html][Documentación]] | ||
|
||
Debe de tener esta forma: | ||
|
||
#+begin_src text :tangle no | ||
hostname:port:database:username:password | ||
#+end_src | ||
|
||
|
||
#+begin_src shell :dir ~ | ||
cp '/home/nanounanue/pCloudDrive/Crypto Folder/.pgpass' . | ||
#+end_src | ||
|
||
|
||
Sus permisos deben de ser =0600= | ||
|
||
#+begin_src shell :dir ~ | ||
chmod 0600 .pgpass | ||
#+end_src | ||
|
||
|
||
|