diff --git a/contrib/pg_tde/expected/access_control.out b/contrib/pg_tde/expected/access_control.out index 2dd199677cfa1..22da3aff28df2 100644 --- a/contrib/pg_tde/expected/access_control.out +++ b/contrib/pg_tde/expected/access_control.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('local-file-provider', '/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/alter_index.out b/contrib/pg_tde/expected/alter_index.out index a4a627e7b97da..667c32687baef 100644 --- a/contrib/pg_tde/expected/alter_index.out +++ b/contrib/pg_tde/expected/alter_index.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/cache_alloc.out b/contrib/pg_tde/expected/cache_alloc.out index bbd27168097fc..528d83ed40c52 100644 --- a/contrib/pg_tde/expected/cache_alloc.out +++ b/contrib/pg_tde/expected/cache_alloc.out @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -- Just checking there are no mem debug WARNINGs during the cache population -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/change_access_method.out b/contrib/pg_tde/expected/change_access_method.out index 3d582af882507..d33b3e68f10aa 100644 --- a/contrib/pg_tde/expected/change_access_method.out +++ b/contrib/pg_tde/expected/change_access_method.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/create_database.out b/contrib/pg_tde/expected/create_database.out index ca31af47b1e3e..e320dea12c0e0 100644 --- a/contrib/pg_tde/expected/create_database.out +++ b/contrib/pg_tde/expected/create_database.out @@ -1,6 +1,6 @@ \! rm -f '/tmp/template_provider_global.per' \! rm -f '/tmp/template_provider.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; CREATE DATABASE template_db; SELECT current_database() AS regress_database \gset diff --git a/contrib/pg_tde/expected/default_principal_key.out b/contrib/pg_tde/expected/default_principal_key.out index a95337077e718..72ec579b6de3b 100644 --- a/contrib/pg_tde/expected/default_principal_key.out +++ b/contrib/pg_tde/expected/default_principal_key.out @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_regression_default_key.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; -CREATE EXTENSION IF NOT EXISTS pg_buffercache; +CREATE EXTENSION pg_tde; +CREATE EXTENSION pg_buffercache; SELECT pg_tde_add_global_key_provider_file('file-provider','/tmp/pg_tde_regression_default_key.per'); pg_tde_add_global_key_provider_file ------------------------------------- diff --git a/contrib/pg_tde/expected/delete_principal_key.out b/contrib/pg_tde/expected/delete_principal_key.out index 17dda7d8ba435..550bcc217b2dd 100644 --- a/contrib/pg_tde/expected/delete_principal_key.out +++ b/contrib/pg_tde/expected/delete_principal_key.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_global_key_provider_file('file-provider','/tmp/pg_tde_test_keyring.per'); pg_tde_add_global_key_provider_file ------------------------------------- diff --git a/contrib/pg_tde/expected/insert_update_delete.out b/contrib/pg_tde/expected/insert_update_delete.out index 88cc211d774f4..97e7f18d1aae5 100644 --- a/contrib/pg_tde/expected/insert_update_delete.out +++ b/contrib/pg_tde/expected/insert_update_delete.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/key_provider.out b/contrib/pg_tde/expected/key_provider.out index 3be6375928e62..8110100372452 100644 --- a/contrib/pg_tde/expected/key_provider.out +++ b/contrib/pg_tde/expected/key_provider.out @@ -2,7 +2,7 @@ \! rm -f '/tmp/global-provider-file-1' \! rm -f '/tmp/pg_tde_test_keyring.per' \! rm -f '/tmp/pg_tde_test_keyring2.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT * FROM pg_tde_key_info(); key_name | provider_name | provider_id | key_creation_time ----------+---------------+-------------+------------------- diff --git a/contrib/pg_tde/expected/pg_tde_is_encrypted.out b/contrib/pg_tde/expected/pg_tde_is_encrypted.out index a6e13a57d9e13..eb3c68fbc7e74 100644 --- a/contrib/pg_tde/expected/pg_tde_is_encrypted.out +++ b/contrib/pg_tde/expected/pg_tde_is_encrypted.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/recreate_storage.out b/contrib/pg_tde/expected/recreate_storage.out index adfca5acb8d38..307f8c96f5c8d 100644 --- a/contrib/pg_tde/expected/recreate_storage.out +++ b/contrib/pg_tde/expected/recreate_storage.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/relocate.out b/contrib/pg_tde/expected/relocate.out index 740a69696e89b..256ad4e314980 100644 --- a/contrib/pg_tde/expected/relocate.out +++ b/contrib/pg_tde/expected/relocate.out @@ -1,6 +1,3 @@ --- Support pg_tde already being installed -SET client_min_messages = 'warning'; -DROP EXTENSION IF EXISTS pg_tde; CREATE SCHEMA other; CREATE EXTENSION pg_tde SCHEMA other; SELECT other.pg_tde_add_database_key_provider_file('file-vault', '/tmp/pg_tde_test_keyring.per'); diff --git a/contrib/pg_tde/expected/tablespace.out b/contrib/pg_tde/expected/tablespace.out index 4349c31ac8019..5d5e290207f99 100644 --- a/contrib/pg_tde/expected/tablespace.out +++ b/contrib/pg_tde/expected/tablespace.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/toast_decrypt.out b/contrib/pg_tde/expected/toast_decrypt.out index 7647a4e6795db..242c266cf4bd6 100644 --- a/contrib/pg_tde/expected/toast_decrypt.out +++ b/contrib/pg_tde/expected/toast_decrypt.out @@ -1,5 +1,5 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/expected/vault_v2_test.out b/contrib/pg_tde/expected/vault_v2_test.out index 33d9f9175444f..74493caefc7ac 100644 --- a/contrib/pg_tde/expected/vault_v2_test.out +++ b/contrib/pg_tde/expected/vault_v2_test.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; \getenv root_token_file VAULT_ROOT_TOKEN_FILE \getenv cacert_file VAULT_CACERT_FILE SELECT pg_tde_add_database_key_provider_vault_v2('vault-incorrect', 'https://127.0.0.1:8200', 'DUMMY-TOKEN', :'root_token_file', :'cacert_file'); diff --git a/contrib/pg_tde/sql/access_control.sql b/contrib/pg_tde/sql/access_control.sql index 78de2d3602d7d..69bc1eb35a6fe 100644 --- a/contrib/pg_tde/sql/access_control.sql +++ b/contrib/pg_tde/sql/access_control.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('local-file-provider', '/tmp/pg_tde_test_keyring.per'); diff --git a/contrib/pg_tde/sql/alter_index.sql b/contrib/pg_tde/sql/alter_index.sql index 23283386f465d..e00f1a407341b 100644 --- a/contrib/pg_tde/sql/alter_index.sql +++ b/contrib/pg_tde/sql/alter_index.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/cache_alloc.sql b/contrib/pg_tde/sql/cache_alloc.sql index 5098c26138681..4f6c9f05fa330 100644 --- a/contrib/pg_tde/sql/cache_alloc.sql +++ b/contrib/pg_tde/sql/cache_alloc.sql @@ -2,7 +2,7 @@ -- Just checking there are no mem debug WARNINGs during the cache population -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/change_access_method.sql b/contrib/pg_tde/sql/change_access_method.sql index cd4ff512c7e9d..e2a1faeef2394 100644 --- a/contrib/pg_tde/sql/change_access_method.sql +++ b/contrib/pg_tde/sql/change_access_method.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key', 'file-vault'); diff --git a/contrib/pg_tde/sql/create_database.sql b/contrib/pg_tde/sql/create_database.sql index 604293dd24a5a..a1a3aa6f1649d 100644 --- a/contrib/pg_tde/sql/create_database.sql +++ b/contrib/pg_tde/sql/create_database.sql @@ -1,7 +1,7 @@ \! rm -f '/tmp/template_provider_global.per' \! rm -f '/tmp/template_provider.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; CREATE DATABASE template_db; diff --git a/contrib/pg_tde/sql/default_principal_key.sql b/contrib/pg_tde/sql/default_principal_key.sql index 20acfd3eb3e99..8d2c60c63b85e 100644 --- a/contrib/pg_tde/sql/default_principal_key.sql +++ b/contrib/pg_tde/sql/default_principal_key.sql @@ -1,7 +1,7 @@ \! rm -f '/tmp/pg_tde_regression_default_key.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; -CREATE EXTENSION IF NOT EXISTS pg_buffercache; +CREATE EXTENSION pg_tde; +CREATE EXTENSION pg_buffercache; SELECT pg_tde_add_global_key_provider_file('file-provider','/tmp/pg_tde_regression_default_key.per'); diff --git a/contrib/pg_tde/sql/delete_principal_key.sql b/contrib/pg_tde/sql/delete_principal_key.sql index 262d456933555..abc4c574b5616 100644 --- a/contrib/pg_tde/sql/delete_principal_key.sql +++ b/contrib/pg_tde/sql/delete_principal_key.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_global_key_provider_file('file-provider','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_global_key_provider('defalut-key','file-provider'); diff --git a/contrib/pg_tde/sql/insert_update_delete.sql b/contrib/pg_tde/sql/insert_update_delete.sql index 3ec1a8014d4e4..be2b3ff61f451 100644 --- a/contrib/pg_tde/sql/insert_update_delete.sql +++ b/contrib/pg_tde/sql/insert_update_delete.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/key_provider.sql b/contrib/pg_tde/sql/key_provider.sql index ad4467e787dd3..072176cccc836 100644 --- a/contrib/pg_tde/sql/key_provider.sql +++ b/contrib/pg_tde/sql/key_provider.sql @@ -3,7 +3,7 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' \! rm -f '/tmp/pg_tde_test_keyring2.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT * FROM pg_tde_key_info(); diff --git a/contrib/pg_tde/sql/pg_tde_is_encrypted.sql b/contrib/pg_tde/sql/pg_tde_is_encrypted.sql index 5fb492c152146..36f1aa5f708b6 100644 --- a/contrib/pg_tde/sql/pg_tde_is_encrypted.sql +++ b/contrib/pg_tde/sql/pg_tde_is_encrypted.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/recreate_storage.sql b/contrib/pg_tde/sql/recreate_storage.sql index 60804f6e379db..26770e14e58e6 100644 --- a/contrib/pg_tde/sql/recreate_storage.sql +++ b/contrib/pg_tde/sql/recreate_storage.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/relocate.sql b/contrib/pg_tde/sql/relocate.sql index f3a79b279789e..1f06077208a0a 100644 --- a/contrib/pg_tde/sql/relocate.sql +++ b/contrib/pg_tde/sql/relocate.sql @@ -1,7 +1,3 @@ --- Support pg_tde already being installed -SET client_min_messages = 'warning'; -DROP EXTENSION IF EXISTS pg_tde; - CREATE SCHEMA other; CREATE EXTENSION pg_tde SCHEMA other; diff --git a/contrib/pg_tde/sql/tablespace.sql b/contrib/pg_tde/sql/tablespace.sql index 413a1159ba2de..920d51bf8cd6e 100644 --- a/contrib/pg_tde/sql/tablespace.sql +++ b/contrib/pg_tde/sql/tablespace.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/toast_decrypt.sql b/contrib/pg_tde/sql/toast_decrypt.sql index 34d8341c4ebd8..92ad6c104ae64 100644 --- a/contrib/pg_tde/sql/toast_decrypt.sql +++ b/contrib/pg_tde/sql/toast_decrypt.sql @@ -1,6 +1,6 @@ \! rm -f '/tmp/pg_tde_test_keyring.per' -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault','/tmp/pg_tde_test_keyring.per'); SELECT pg_tde_create_key_using_database_key_provider('test-db-key','file-vault'); diff --git a/contrib/pg_tde/sql/vault_v2_test.sql b/contrib/pg_tde/sql/vault_v2_test.sql index 8b95e1cf27dce..d5ffde168426f 100644 --- a/contrib/pg_tde/sql/vault_v2_test.sql +++ b/contrib/pg_tde/sql/vault_v2_test.sql @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; \getenv root_token_file VAULT_ROOT_TOKEN_FILE \getenv cacert_file VAULT_CACERT_FILE diff --git a/contrib/pg_tde/t/basic.pl b/contrib/pg_tde/t/basic.pl index 7d43a3bfcadac..54d19e43f179e 100644 --- a/contrib/pg_tde/t/basic.pl +++ b/contrib/pg_tde/t/basic.pl @@ -16,7 +16,7 @@ $node->append_conf('postgresql.conf', "shared_preload_libraries = 'pg_tde'"); $node->start; -PGTDE::psql($node, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'postgres', 'CREATE EXTENSION pg_tde;'); # Only whitelisted C or security definer functions are granted to public by default PGTDE::psql( diff --git a/contrib/pg_tde/t/change_key_provider.pl b/contrib/pg_tde/t/change_key_provider.pl index 78ee711596290..1ffff0483efbe 100644 --- a/contrib/pg_tde/t/change_key_provider.pl +++ b/contrib/pg_tde/t/change_key_provider.pl @@ -18,7 +18,7 @@ $node->append_conf('postgresql.conf', "shared_preload_libraries = 'pg_tde'"); $node->start; -PGTDE::psql($node, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'postgres', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($node, 'postgres', "SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/change_key_provider_1.per');" diff --git a/contrib/pg_tde/t/crash_recovery.pl b/contrib/pg_tde/t/crash_recovery.pl index 0c4a85c654683..65bae54751666 100644 --- a/contrib/pg_tde/t/crash_recovery.pl +++ b/contrib/pg_tde/t/crash_recovery.pl @@ -20,7 +20,7 @@ }); $node->start; -PGTDE::psql($node, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'postgres', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($node, 'postgres', "SELECT pg_tde_add_global_key_provider_file('global_keyring', '/tmp/crash_recovery.per');" ); diff --git a/contrib/pg_tde/t/expected/basic.out b/contrib/pg_tde/t/expected/basic.out index 7070fb44af8a5..587d8a7a31bf9 100644 --- a/contrib/pg_tde/t/expected/basic.out +++ b/contrib/pg_tde/t/expected/basic.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_proc.oid::regprocedure FROM diff --git a/contrib/pg_tde/t/expected/change_key_provider.out b/contrib/pg_tde/t/expected/change_key_provider.out index cebcfa858ac2d..e444fa7463e37 100644 --- a/contrib/pg_tde/t/expected/change_key_provider.out +++ b/contrib/pg_tde/t/expected/change_key_provider.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/change_key_provider_1.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/t/expected/crash_recovery.out b/contrib/pg_tde/t/expected/crash_recovery.out index 6b5958842a3cd..441c72b0ccd49 100644 --- a/contrib/pg_tde/t/expected/crash_recovery.out +++ b/contrib/pg_tde/t/expected/crash_recovery.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_global_key_provider_file('global_keyring', '/tmp/crash_recovery.per'); pg_tde_add_global_key_provider_file ------------------------------------- diff --git a/contrib/pg_tde/t/expected/key_rotate_tablespace.out b/contrib/pg_tde/t/expected/key_rotate_tablespace.out index c850828f9f95d..0fa6c53b4d074 100644 --- a/contrib/pg_tde/t/expected/key_rotate_tablespace.out +++ b/contrib/pg_tde/t/expected/key_rotate_tablespace.out @@ -1,6 +1,6 @@ SET allow_in_place_tablespaces = true; CREATE TABLESPACE test_tblspace LOCATION ''; CREATE DATABASE tbc TABLESPACE = test_tblspace; -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/key_rotate_tablespace.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/t/expected/multiple_extensions.out b/contrib/pg_tde/t/expected/multiple_extensions.out index a27fc6c8113ff..e5903d1bd401d 100644 --- a/contrib/pg_tde/t/expected/multiple_extensions.out +++ b/contrib/pg_tde/t/expected/multiple_extensions.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; CREATE TABLE test_enc1 (id SERIAL, k INTEGER, PRIMARY KEY (id)) USING tde_heap; INSERT INTO test_enc1 (k) VALUES (5), (6); SELECT * FROM test_enc1 ORDER BY id; diff --git a/contrib/pg_tde/t/expected/replication.out b/contrib/pg_tde/t/expected/replication.out index 9b44c223f2943..679adc1df335c 100644 --- a/contrib/pg_tde/t/expected/replication.out +++ b/contrib/pg_tde/t/expected/replication.out @@ -1,5 +1,5 @@ -- At primary -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/replication.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/t/expected/rotate_key.out b/contrib/pg_tde/t/expected/rotate_key.out index 4fc776991159c..65d542eeaf408 100644 --- a/contrib/pg_tde/t/expected/rotate_key.out +++ b/contrib/pg_tde/t/expected/rotate_key.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/rotate_key.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/t/expected/tde_heap.out b/contrib/pg_tde/t/expected/tde_heap.out index e0083b15570b0..a5f7e3ee04feb 100644 --- a/contrib/pg_tde/t/expected/tde_heap.out +++ b/contrib/pg_tde/t/expected/tde_heap.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/tde_heap.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/t/expected/unlogged_tables.out b/contrib/pg_tde/t/expected/unlogged_tables.out index 4c854576016e5..09532ce5ffeec 100644 --- a/contrib/pg_tde/t/expected/unlogged_tables.out +++ b/contrib/pg_tde/t/expected/unlogged_tables.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/unlogged_tables.per'); pg_tde_add_database_key_provider_file --------------------------------------- diff --git a/contrib/pg_tde/t/expected/wal_encrypt.out b/contrib/pg_tde/t/expected/wal_encrypt.out index a1a22557980a2..183f20b9beda9 100644 --- a/contrib/pg_tde/t/expected/wal_encrypt.out +++ b/contrib/pg_tde/t/expected/wal_encrypt.out @@ -1,4 +1,4 @@ -CREATE EXTENSION IF NOT EXISTS pg_tde; +CREATE EXTENSION pg_tde; SELECT pg_tde_add_global_key_provider_file('file-keyring-010', '/tmp/wal_encrypt.per'); pg_tde_add_global_key_provider_file ------------------------------------- diff --git a/contrib/pg_tde/t/key_rotate_tablespace.pl b/contrib/pg_tde/t/key_rotate_tablespace.pl index ff30aa3f33dcc..c1c85431cacb8 100644 --- a/contrib/pg_tde/t/key_rotate_tablespace.pl +++ b/contrib/pg_tde/t/key_rotate_tablespace.pl @@ -22,7 +22,7 @@ PGTDE::psql($node, 'postgres', 'CREATE DATABASE tbc TABLESPACE = test_tblspace;'); -PGTDE::psql($node, 'tbc', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'tbc', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($node, 'tbc', "SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/key_rotate_tablespace.per');" ); diff --git a/contrib/pg_tde/t/multiple_extensions.pl b/contrib/pg_tde/t/multiple_extensions.pl index 3f52d0ea6528c..1a16c2d5cc502 100644 --- a/contrib/pg_tde/t/multiple_extensions.pl +++ b/contrib/pg_tde/t/multiple_extensions.pl @@ -50,10 +50,8 @@ PGTDE::append_to_debug_file($stdout); # Create pg_tde extension -($cmdret, $stdout, $stderr) = $node->psql( - 'postgres', - 'CREATE EXTENSION IF NOT EXISTS pg_tde;', - extra_params => ['-a']); +($cmdret, $stdout, $stderr) = + $node->psql('postgres', 'CREATE EXTENSION pg_tde;', extra_params => ['-a']); ok($cmdret == 0, "CREATE PGTDE EXTENSION"); PGTDE::append_to_result_file($stdout); diff --git a/contrib/pg_tde/t/pg_tde_change_key_provider.pl b/contrib/pg_tde/t/pg_tde_change_key_provider.pl index fbcae2e77b9c2..c16f6c3591ba2 100644 --- a/contrib/pg_tde/t/pg_tde_change_key_provider.pl +++ b/contrib/pg_tde/t/pg_tde_change_key_provider.pl @@ -11,7 +11,7 @@ $node->append_conf('postgresql.conf', q{shared_preload_libraries = 'pg_tde'}); $node->start; -$node->safe_psql('postgres', q{CREATE EXTENSION IF NOT EXISTS pg_tde}); +$node->safe_psql('postgres', q{CREATE EXTENSION pg_tde}); $node->safe_psql('postgres', q{SELECT pg_tde_add_global_key_provider_file('global-provider', '/tmp/pg_tde_change_key_provider-global')} ); diff --git a/contrib/pg_tde/t/pg_waldump_basic.pl b/contrib/pg_tde/t/pg_waldump_basic.pl index 5f86b7929ce32..57bc28cb38368 100644 --- a/contrib/pg_tde/t/pg_waldump_basic.pl +++ b/contrib/pg_tde/t/pg_waldump_basic.pl @@ -28,7 +28,7 @@ }); $node->start; -$node->safe_psql('postgres', "CREATE EXTENSION IF NOT EXISTS pg_tde;"); +$node->safe_psql('postgres', "CREATE EXTENSION pg_tde;"); $node->safe_psql('postgres', "SELECT pg_tde_add_global_key_provider_file('file-keyring-wal', '/tmp/pg_waldump_basic.per');" ); diff --git a/contrib/pg_tde/t/pg_waldump_fullpage.pl b/contrib/pg_tde/t/pg_waldump_fullpage.pl index b543b46bea456..5d5fe24c7e4a6 100644 --- a/contrib/pg_tde/t/pg_waldump_fullpage.pl +++ b/contrib/pg_tde/t/pg_waldump_fullpage.pl @@ -42,7 +42,7 @@ sub get_block_lsn }); $node->start; -$node->safe_psql('postgres', "CREATE EXTENSION IF NOT EXISTS pg_tde;"); +$node->safe_psql('postgres', "CREATE EXTENSION pg_tde;"); $node->safe_psql('postgres', "SELECT pg_tde_add_global_key_provider_file('file-keyring-wal', '/tmp/pg_waldump_fullpage.per');" ); diff --git a/contrib/pg_tde/t/replication.pl b/contrib/pg_tde/t/replication.pl index 0a53fead4d3cb..573ef3e8050cf 100644 --- a/contrib/pg_tde/t/replication.pl +++ b/contrib/pg_tde/t/replication.pl @@ -28,7 +28,7 @@ PGTDE::append_to_result_file("-- At primary"); -PGTDE::psql($primary, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($primary, 'postgres', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($primary, 'postgres', "SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/replication.per');" ); diff --git a/contrib/pg_tde/t/rotate_key.pl b/contrib/pg_tde/t/rotate_key.pl index b836e664d1370..8b65e5fb224dc 100644 --- a/contrib/pg_tde/t/rotate_key.pl +++ b/contrib/pg_tde/t/rotate_key.pl @@ -19,7 +19,7 @@ $node->append_conf('postgresql.conf', "shared_preload_libraries = 'pg_tde'"); $node->start; -PGTDE::psql($node, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'postgres', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($node, 'postgres', "SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/rotate_key.per');" diff --git a/contrib/pg_tde/t/tde_heap.pl b/contrib/pg_tde/t/tde_heap.pl index f0e6c0376b965..a8fecc3d7df4f 100644 --- a/contrib/pg_tde/t/tde_heap.pl +++ b/contrib/pg_tde/t/tde_heap.pl @@ -16,7 +16,7 @@ $node->append_conf('postgresql.conf', "shared_preload_libraries = 'pg_tde'"); $node->start; -PGTDE::psql($node, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'postgres', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($node, 'postgres', "SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/tde_heap.per');" diff --git a/contrib/pg_tde/t/unlogged_tables.pl b/contrib/pg_tde/t/unlogged_tables.pl index 742240d0f2169..365f89c8fa0c9 100644 --- a/contrib/pg_tde/t/unlogged_tables.pl +++ b/contrib/pg_tde/t/unlogged_tables.pl @@ -16,7 +16,7 @@ $node->append_conf('postgresql.conf', "shared_preload_libraries = 'pg_tde'"); $node->start; -PGTDE::psql($node, 'postgres', 'CREATE EXTENSION IF NOT EXISTS pg_tde;'); +PGTDE::psql($node, 'postgres', 'CREATE EXTENSION pg_tde;'); PGTDE::psql($node, 'postgres', "SELECT pg_tde_add_database_key_provider_file('file-vault', '/tmp/unlogged_tables.per');" ); diff --git a/contrib/pg_tde/t/wal_encrypt.pl b/contrib/pg_tde/t/wal_encrypt.pl index 33b3adfa7136e..7db5cd28dbf2a 100644 --- a/contrib/pg_tde/t/wal_encrypt.pl +++ b/contrib/pg_tde/t/wal_encrypt.pl @@ -19,7 +19,7 @@ #$node->append_conf('postgresql.conf', "pg_tde.wal_encrypt = 1"}); $node->start; -PGTDE::psql($node, 'postgres', "CREATE EXTENSION IF NOT EXISTS pg_tde;"); +PGTDE::psql($node, 'postgres', "CREATE EXTENSION pg_tde;"); PGTDE::psql($node, 'postgres', "SELECT pg_tde_add_global_key_provider_file('file-keyring-010', '/tmp/wal_encrypt.per');"