You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello!
In my case, I'd like to install sonarqube+postgresql as services with Chef instruments (chef-client and cookbooks). I started to develop such decision and faced obstacles with restarting/starting postgresql service. So, try to answer this question to you.
👻 Brief Description
So, after reading and understanding what kind of resources I need, start to create custom recipe, that it is:
postgresql_server_install'Install PostgreSQL Server'doversionnode['e3s']['postgresql']['version']action:installendservice'postgresql'doaction:restartendpostgresql_user'Create defined user for Sonarqube'docreate_usernode['e3s']['sonarqube']['jdbc']['username']createdbtruepasswordnode['e3s']['sonarqube']['jdbc']['password']endpostgresql_database'Create database for Sonarqube'dodatabasenode['e3s']['sonarqube']['jdbc']['database_name']ownernode['e3s']['sonarqube']['jdbc']['username']end
@Pursu1tOfHapp1ness does journalctl -u postgresql show for the output logs? Also you might look at other logs for the pg server that might give you some help. I'm not sure this is a problem with our cookbook or not, it likely might be something else related to including sonarqube. Thanks for reporting!
And maybe logs from /var/log/postgresql will be useful:
2021-05-21 11:23:09.316 UTC [5852] LOG: starting PostgreSQL 12.7 (Debian 12.7-1.pgdg100+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
2021-05-21 11:23:09.316 UTC [5852] LOG: listening on IPv4 address "127.0.0.1", port 5432
2021-05-21 11:23:09.317 UTC [5852] LOG: could not bind IPv6 address "::1": Cannot assign requested address
2021-05-21 11:23:09.317 UTC [5852] HINT: Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
2021-05-21 11:23:09.318 UTC [5852] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2021-05-21 11:23:09.336 UTC [5853] LOG: database system was shut down at 2021-05-21 11:23:07 UTC
2021-05-21 11:23:09.341 UTC [5852] LOG: database system is ready to accept connections
🗣️ Foreword
Hello!
In my case, I'd like to install sonarqube+postgresql as services with Chef instruments (chef-client and cookbooks). I started to develop such decision and faced obstacles with restarting/starting postgresql service. So, try to answer this question to you.
👻 Brief Description
So, after reading and understanding what kind of resources I need, start to create custom recipe, that it is:
Variables:
.kitchen.yml:
So, after kitchen is creating and start to converge, in logs I see:
🥞 Cookbook version
Latest cookbook version of postgresql:
postgresql (8.2.1)
apt (>= 0.0.0)
yum-epel (>= 0.0.0)
👩🍳 Chef-Infra Version
Version of chef-client in my environment:
chef-client version: 14.15.6
delivery version: master (4b21ec7e07fdfa82e86aa80e4f2372dde8e368bb)
berks version: 7.0.8
kitchen version: 1.25.0
inspec version: 3.9.3
🎩 Platform details
CentOS Linux release 7.9.2009 (Core)
Steps To Reproduce
Steps to reproduce the behavior:
🚓 Expected behavior
Expect to restart/reload postgresql service as normal service, without timeout issues.
➕ Additional context
Vice verse, if I use in .kitchen.yml next code:
.kitchen.yml:
Everything will be good. Thanks for answering!
The text was updated successfully, but these errors were encountered: