Skip to content
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package com.softeer5.uniro_backend.common.config;

import java.util.List;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import io.swagger.v3.oas.models.Components;
import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.info.Info;
import io.swagger.v3.oas.models.servers.Server;

@Configuration
public class SwaggerConfig {

@Bean
public OpenAPI openAPI() {
Server devServer = new Server();
devServer.setUrl("https://api.uniro.site");
OpenAPI info = new OpenAPI().components(new Components()).info(new Info());
info.setServers(List.of(devServer));
return info;
}

}
8 changes: 4 additions & 4 deletions uniro_backend/src/main/resources/application-local.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
spring:
datasource:
url: jdbc:h2:mem:uniro-local-db;mode=mysql
driverClassName: org.h2.Driver
username: sa
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://localhost:3306/uniro?useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=UTC
username: root
password:
jpa:
database-platform: org.hibernate.dialect.H2Dialect
hibernate:
ddl-auto: create
properties:
hibernate:
format_sql: true
dialect: org.hibernate.spatial.dialect.mysql.MySQLSpatialDialect
show_sql: true
open-in-view: false
defer-datasource-initialization: true
Expand Down