On Sat, 15 Sep 2018 11:17:27 -0700, Chris Bennett
<cpb_po...@bennettconstruction.us> wrote:

> Perfect.
> Thanks. You don't know how many times I've had to re-do after grabbing
> that first line without UTF-8.

Thanks for your feedback!

<pea> danj: about the diff for pgsql. I agree with the utf-8 bit but
for the scram-sha, i'm not sure. Not all clients support it right now.
It could be annoying

Here's a diff that only deals with the encoding stuff. OK?

Also I can't really see a case where a lib without support for the new
auth method could be a problem. If it doesn't support it, you can just
set MD5 for the app user in your pg_hba.conf, no? Am I missing
something?


Index: Makefile
===================================================================
RCS file: /cvs/ports/databases/postgresql/Makefile,v
retrieving revision 1.240
diff -u -p -r1.240 Makefile
--- Makefile    6 Sep 2018 19:08:59 -0000       1.240
+++ Makefile    17 Sep 2018 21:13:05 -0000
@@ -17,7 +17,7 @@ PKGNAME-contrib=postgresql-contrib-${VER
 PKGNAME-plpython=postgresql-plpython-${VERSION}
 PKGNAME-pg_upgrade=postgresql-pg_upgrade-${VERSION}
 REVISION-main= 0
-REVISION-server=1
+REVISION-server=2
 
 CATEGORIES=    databases
 SHARED_LIBS=   ecpg            7.9 \
Index: pkg/README-server
===================================================================
RCS file: /cvs/ports/databases/postgresql/pkg/README-server,v
retrieving revision 1.24
diff -u -p -r1.24 README-server
--- pkg/README-server   4 Sep 2018 12:46:10 -0000       1.24
+++ pkg/README-server   17 Sep 2018 21:13:05 -0000
@@ -19,16 +19,7 @@ We will be prompted for a password to pr
 
        # su - _postgresql
        $ mkdir /var/postgresql/data
-       $ initdb -D /var/postgresql/data -U postgres -A md5 -W
-
-Please note that by default the cluster's encoding will be SQL_ASCII. If
-you want to have another default encoding, use the option -E with initdb:
-
-       $ initdb -D /var/postgresql/data -U postgres -E UTF8 -A md5 -W
-
-If your cluster is already created, you can specify another encoding when
-you create a new database with this command:
-       CREATE DATABASE xxx TEMPLATE template0 ENCODING 'xxx' ;
+       $ initdb -D /var/postgresql/data -U postgres -A md5 -E UTF8 -W
 
 It is strongly advised that you do not work with the postgres dba account
 other than creating more users and/or databases or for administrative tasks.
@@ -127,9 +118,10 @@ to the current version.
 4) Backup your old data directory:
 # mv /var/postgresql/data /var/postgresql/data-${PREV_MAJOR}
 
-5) Create a new data directory (adding -E UTF8 to the initdb line if needed):
+5) Create a new data directory:
 # su _postgresql -c "mkdir /var/postgresql/data"
-# su _postgresql -c "initdb -D /var/postgresql/data -U postgres -A md5 -W"
+# su _postgresql -c \
+    "initdb -D /var/postgresql/data -U postgres -A md5 -E UTF8 -W"
 
 6) Restore your old pg_hba.conf and (if used) SSL certificates
 # su _postgresql -c \
@@ -162,9 +154,10 @@ faster than a dump and reload, especiall
 3) Backup your old data directory:
 # mv /var/postgresql/data /var/postgresql/data-${PREV_MAJOR}
 
-4) Create a new data directory (adding -E UTF8 to the initdb line if needed):
+4) Create a new data directory:
 # su _postgresql -c "mkdir /var/postgresql/data"
-# su _postgresql -c "initdb -D /var/postgresql/data -U postgres -A md5 -W"
+# su _postgresql -c \
+    "initdb -D /var/postgresql/data -U postgres -A md5 -E UTF8 -W"
 
 5) Restore your old pg_hba.conf and (if used) SSL certificates
 # su _postgresql -c \


Reply via email to