Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 136d172

Browse files
authoredJan 2, 2025··
Pmm3 pgsql portfix (#106)
* Updates to fix PGSQL port
1 parent 204660f commit 136d172

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed
 

‎pmm_qa/pdpgsql_pgsm_setup.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
pgstat_monitor_branch: "{{ lookup('vars', 'extra_pgstat_monitor_branch', default=lookup('env','PGSTAT_MONITOR_BRANCH') | default('2.1.0', true) ) }}"
1616
pgstat_monitor_repo: "{{ lookup('vars', 'extra_pgstat_monitor_repo', default=lookup('env','PGSTAT_MONITOR_REPO') | default('percona/pg_stat_monitor', true) ) }}"
1717
use_socket: "{{ lookup('vars', 'extra_pdpgsql_version', default=lookup('env','USE_SOCKET') | default('', true) ) }}"
18+
port: "{{ lookup('vars', 'extra_pdpgsql_port', default=lookup('env','PORT') | default(5447, true) ) }}"
1819
distribution: "{{ lookup('vars', 'extra_pdpgsql_distribution', default=lookup('env','DISTRIBUTION') | default('PPG', true) ) }}"
1920

2021
tasks:
@@ -32,7 +33,7 @@
3233
- name: Prepare Container for PostgreSQL
3334
shell: >
3435
sudo docker run -d --name={{ pdpgsql_pgsm_container }}
35-
-p 5447:5432
36+
-p {{ port }}:5432
3637
phusion/baseimage:jammy-1.0.1
3738
3839
- name: Copy all required Artifacts to the docker pdpgsql_pgsm_container
@@ -46,7 +47,7 @@
4647
- name: Execute Setup script inside the pdpgsql pdpgsql_pgsm_container
4748
shell: "{{ item }}"
4849
with_items:
49-
- docker exec {{ pdpgsql_pgsm_container }} bash -xe ./pg_stat_monitor_setup.sh --distribution {{ distribution }} --pgsql_version {{ pdpgsql_version }} --pgstat_monitor_branch {{ pgstat_monitor_branch }} --pgstat_monitor_repo {{ pgstat_monitor_repo }} > setup_pdpgsql_pgsm_{{ pdpgsql_version }}.log
50+
- docker exec {{ pdpgsql_pgsm_container }} bash -xe ./pg_stat_monitor_setup.sh --distribution {{ distribution }} --pgsql_version {{ pdpgsql_version }} --pgstat_monitor_branch {{ pgstat_monitor_branch }} --pgstat_monitor_repo {{ pgstat_monitor_repo }} > setup_{{ pdpgsql_pgsm_container }}.log
5051

5152
- name: Install pmm2-client on the pdpgsql_pgsm_container
5253
shell: "{{ item }}"

‎pmm_qa/pmm-framework.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,7 @@ def setup_pdpgsql(db_type, db_version=None, db_config=None, args=None):
284284
'CLIENT_VERSION': get_value('CLIENT_VERSION', db_type, args, db_config),
285285
'USE_SOCKET': get_value('USE_SOCKET', db_type, args, db_config),
286286
'ADMIN_PASSWORD': os.getenv('ADMIN_PASSWORD') or args.pmm_server_password or 'admin',
287+
'PORT': 5447,
287288
'DISTRIBUTION': '',
288289
'PMM_QA_GIT_BRANCH': os.getenv('PMM_QA_GIT_BRANCH') or 'v3'
289290
}
@@ -343,6 +344,7 @@ def setup_pgsql(db_type, db_version=None, db_config=None, args=None):
343344
'CLIENT_VERSION': get_value('CLIENT_VERSION', db_type, args, db_config),
344345
'USE_SOCKET': get_value('USE_SOCKET', db_type, args, db_config),
345346
'ADMIN_PASSWORD': os.getenv('ADMIN_PASSWORD') or args.pmm_server_password or 'admin',
347+
'PORT': 5448,
346348
'DISTRIBUTION': 'PGDG',
347349
'PMM_QA_GIT_BRANCH': os.getenv('PMM_QA_GIT_BRANCH') or 'v3'
348350
}

0 commit comments

Comments
 (0)
Please sign in to comment.