Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lib-v2: fix healthcheck for pg #695

Merged
merged 1 commit into from
Oct 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 2 additions & 1 deletion library/2.0.0/deps.py → library/2.0.1/deps.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,8 @@ def perform_action(action):
print("Permissions are correct. Skipping...")

print(f"Time taken: {(time.time() - start_time) * 1000:.2f}ms")
print(f"=== Finished applying configuration on volume with identifier [{action['identifier']}] ===")
print(f"=== Finished applying configuration on volume with identifier [{action['identifier']}] ==")
print()

if __name__ == "__main__":
start_time = time.time()
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ def postgres_test(config: dict) -> str:
port = get_key(config, "port", 5432, False)
host = get_key(config, "host", "127.0.0.1", False)

return f"pg_isready -h {host} -p {port} -U $POSTGRES_USERNAME -d $POSTGRES_DATABASE"
return f"pg_isready -h {host} -p {port} -U $POSTGRES_USER -d $POSTGRES_DB"


def mariadb_test(config: dict) -> str:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def test_add_postgres(mock_values):
assert output["services"]["pg_container"]["deploy"]["resources"]["limits"]["cpus"] == "2.0"
assert output["services"]["pg_container"]["deploy"]["resources"]["limits"]["memory"] == "4096M"
assert output["services"]["pg_container"]["healthcheck"] == {
"test": "pg_isready -h 127.0.0.1 -p 5432 -U $$POSTGRES_USERNAME -d $$POSTGRES_DATABASE",
"test": "pg_isready -h 127.0.0.1 -p 5432 -U $$POSTGRES_USER -d $$POSTGRES_DB",
"interval": "10s",
"timeout": "5s",
"retries": 30,
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ def test_postgres_healthcheck(mock_values):
output = render.render()
assert (
output["services"]["test_container"]["healthcheck"]["test"]
== "pg_isready -h 127.0.0.1 -p 5432 -U $$POSTGRES_USERNAME -d $$POSTGRES_DATABASE"
== "pg_isready -h 127.0.0.1 -p 5432 -U $$POSTGRES_USER -d $$POSTGRES_DB"
)


Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion library/hashes.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
0.0.1: f074617a82a86d2a6cc78a4c8a4296fc9d168e456f12713e50c696557b302133
1.1.4: 6e32ff5969906d9c3a10fea2b17fdd3197afb052d3432344da03188d8a907113
2.0.0: 1d4f6760d7abd712271ff40ae0cabe3285f34a1f84c6922709d51f1f0bf5ce33
2.0.1: 77e44b15832ac747aadc0d04c3eaac54cd0a9810cf761670b0215cb9c6aa7608
Loading