Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 168bc695b6 |
@@ -2,6 +2,7 @@ WEB_PROTOCOL=http
|
||||
WEB_ADDRESS=localhost
|
||||
WEB_RESET_ADDRESS=localhost/reset
|
||||
WEB_PORT=3200
|
||||
WEB_ORIGIN=http://localhost:3001
|
||||
|
||||
DB_HOSTNAME=database
|
||||
DB_DATABASE=auth
|
||||
|
||||
+4
-3
@@ -29,8 +29,9 @@ const question = (prompt, def = null) => {
|
||||
(async () => {
|
||||
//project configuration
|
||||
const appName = await question('App Name', 'auth');
|
||||
const appWebOrigin = await question('Web Origin', `example.com`);
|
||||
const appWebAddress = await question('Web Addr', `${appName}.${appWebOrigin}`);
|
||||
const appWebProtocol = await question('Web Protocol', 'https');
|
||||
const appWebOrigin = await question('Web Origin', `${appWebProtocol}://example.com`); //TODO: clean these up properly
|
||||
const appWebAddress = await question('Web Addr', `${appName}.example.com`);
|
||||
const postValidationHookArray = await question('Post Validation Hook Array', '');
|
||||
const resetAddress = await question('Reset Addr', `example.com/reset`);
|
||||
const appPort = await question('App Port', '3200');
|
||||
@@ -70,7 +71,7 @@ services:
|
||||
- "traefik.http.routers.${appName}router.service=${appName}service@docker"
|
||||
- "traefik.http.services.${appName}service.loadbalancer.server.port=${appPort}"
|
||||
environment:
|
||||
- WEB_PROTOCOL=https
|
||||
- WEB_PROTOCOL=${appWebProtocol}
|
||||
- WEB_ORIGIN=${appWebOrigin}
|
||||
- WEB_ADDRESS=${appWebAddress}
|
||||
- HOOK_POST_VALIDATION_ARRAY=${postValidationHookArray}
|
||||
|
||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "auth-server",
|
||||
"version": "1.6.1",
|
||||
"version": "1.6.2",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "auth-server",
|
||||
"version": "1.6.1",
|
||||
"version": "1.6.2",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"bcryptjs": "^2.4.3",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "auth-server",
|
||||
"version": "1.6.1",
|
||||
"version": "1.6.2",
|
||||
"description": "An API centric auth server. Uses Sequelize and mariaDB by default.",
|
||||
"main": "server/server.js",
|
||||
"scripts": {
|
||||
|
||||
+1
-1
@@ -13,7 +13,7 @@ app.use(express.json());
|
||||
|
||||
app.use(cors({
|
||||
credentials: true,
|
||||
origin: [`${process.env.WEB_PROTOCOL}://${process.env.WEB_ORIGIN}`],
|
||||
origin: [`${process.env.WEB_ORIGIN}`],
|
||||
allowedHeaders: ['Origin', 'X-Requested-With', 'Content-Type', 'Accept', 'Authorization', 'Set-Cookie'],
|
||||
exposedHeaders: ['Origin', 'X-Requested-With', 'Content-Type', 'Accept', 'Authorization', 'Set-Cookie'],
|
||||
}));
|
||||
|
||||
Reference in New Issue
Block a user