Skip to content
This repository was archived by the owner on Jan 20, 2024. It is now read-only.

Commit c9fa70d

Browse files
committed
fixes #71 update mysql script and service.yml to use mysqluser instead of root
1 parent 8b9678e commit c9fa70d

File tree

8 files changed

+18
-15
lines changed

8 files changed

+18
-15
lines changed

db/mysql/config/oauth2-client/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/config/oauth2-code/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/config/oauth2-key/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/config/oauth2-refresh-token/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/config/oauth2-service/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/config/oauth2-token/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/config/oauth2-user/service.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ singletons:
3636
- javax.sql.DataSource:
3737
- com.zaxxer.hikari.HikariDataSource:
3838
jdbcUrl: jdbc:mysql://mysqldb:3306/oauth2?useSSL=false
39-
username: root
40-
password: my-secret-pw
39+
username: mysqluser
40+
password: mysqlpw
4141
maximumPoolSize: 15
4242
useServerPrepStmts: true
4343
cachePrepStmts: true

db/mysql/create_mysql.sql

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
DROP DATABASE IF EXISTS oauth2;
22
CREATE DATABASE oauth2;
3+
4+
GRANT ALL PRIVILEGES ON oauth2.* TO 'mysqluser'@'%' WITH GRANT OPTION;
5+
36
USE oauth2;
47

58
DROP TABLE IF EXISTS user_profile;
@@ -139,7 +142,7 @@ ENGINE=INNODB;
139142

140143

141144
INSERT INTO user_profile(user_id, user_type, first_name, last_name, email, password)
142-
VALUES('admin', 'admin', 'admin', 'admin', 'admin@cibc.com', '1000:5b39342c202d37372c203132302c202d3132302c2034372c2032332c2034352c202d34342c202d31362c2034372c202d35392c202d35362c2039302c202d352c202d38322c202d32385d:949e6fcf9c4bb8a3d6a8c141a3a9182a572fb95fe8ccdc93b54ba53df8ef2e930f7b0348590df0d53f242ccceeae03aef6d273a34638b49c559ada110ec06992');
145+
VALUES('admin', 'admin', 'admin', 'admin', 'admin@networknt.com', '1000:5b39342c202d37372c203132302c202d3132302c2034372c2032332c2034352c202d34342c202d31362c2034372c202d35392c202d35362c2039302c202d352c202d38322c202d32385d:949e6fcf9c4bb8a3d6a8c141a3a9182a572fb95fe8ccdc93b54ba53df8ef2e930f7b0348590df0d53f242ccceeae03aef6d273a34638b49c559ada110ec06992');
143146

144147
INSERT INTO client (client_id, client_secret, client_type, client_profile, client_name, client_desc, scope, redirect_uri, owner_id)
145148
VALUES('f7d42348-c647-4efb-a52d-4c5787421e72', '1000:5b37332c202d36362c202d36392c203131362c203132362c2036322c2037382c20342c202d37382c202d3131352c202d35332c202d34352c202d342c202d3132322c203130322c2033325d:29ad1fe88d66584c4d279a6f58277858298dbf9270ffc0de4317a4d38ba4b41f35f122e0825c466f2fa14d91e17ba82b1a2f2a37877a2830fae2973076d93cc2', 'public', 'mobile', 'PetStore Web Server', 'PetStore Web Server that calls PetStore API', 'petstore.r petstore.w', 'http://localhost:8080/authorization', 'admin');

0 commit comments

Comments
 (0)