Skip to content

Commit

Permalink
add postgres
Browse files Browse the repository at this point in the history
  • Loading branch information
Roman3455 committed Dec 31, 2024
1 parent 933d042 commit 0464d2e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ dependencies {

implementation("com.h2database:h2:2.2.224")
implementation("com.zaxxer:HikariCP:6.2.1")
implementation("org.postgresql:postgresql:42.7.2")

testImplementation(platform("org.junit:junit-bom:5.10.0"))
testImplementation("org.junit.jupiter:junit-jupiter")
Expand Down
1 change: 1 addition & 0 deletions app/src/main/java/hexlet/code/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ public static void main(String[] args) throws SQLException, IOException {
}

private static int getPort() {
System.out.println(System.getenv().get("PORT"));
return Integer.parseInt(System.getenv().getOrDefault("PORT", "7070"));
}

Expand Down

0 comments on commit 0464d2e

Please sign in to comment.