-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: set liquibase config automatically
- Loading branch information
Showing
1 changed file
with
19 additions
and
0 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
...c/main/java/be/vlaanderen/informatievlaanderen/ldes/server/liquibase/LiquibaseConfig.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,19 @@ | ||
package be.vlaanderen.informatievlaanderen.ldes.server.liquibase; | ||
|
||
import liquibase.integration.spring.SpringLiquibase; | ||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
|
||
import javax.sql.DataSource; | ||
|
||
@Configuration | ||
public class LiquibaseConfig { | ||
|
||
@Bean | ||
public SpringLiquibase liquibase(DataSource dataSource) { | ||
SpringLiquibase liquibase = new SpringLiquibase(); | ||
liquibase.setChangeLog("classpath:/db/changelog/master.xml"); // Set your desired change log path | ||
liquibase.setDataSource(dataSource); // Configure your data source | ||
return liquibase; | ||
} | ||
} |