-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added port configuration to deploy on railway
- Loading branch information
1 parent
06c7e28
commit 1f5cc92
Showing
2 changed files
with
14 additions
and
1 deletion.
There are no files selected for viewing
13 changes: 13 additions & 0 deletions
13
src/main/java/com/alura/aluraflixapi/infraestructure/railway/RailwayConfig.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package com.alura.aluraflixapi.infraestructure.railway; | ||
|
||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
|
||
@Configuration | ||
public class RailwayConfig { | ||
|
||
@Bean | ||
String getPort(){ | ||
return System.getenv("PORT"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters