thunderhub/next.config.js
Anthony Potdevin 9d73c30fb4
feat: server authentication (#38)
* feat:  server sso auth

* chore: 🔧 continue sso integration

* fix: 🐛 correct filter

* chore: 🔧 add resolver types

* chore: 🔧 linter sort imports

* fix: 🐛 duplicate imports

* chore: 🔧 change auth context

* feat:  add accounts read and query

* fix: 🐛 small changes

* chore: 🔧 continue integration

* chore: 🔧 add auth

* chore: 🔧 switch to new context

* fix: 🐛 imports and account context

* chore: 🔧 add session token query

* chore: 🔧 change server auth

* chore: 🔧 add sso to server accounts query

* chore: 🔧 cleanup and small fixes

* chore: 🔧 separate generated files

* refactor: ♻️ change graphql imports

* fix: 🐛 add id to params

* fix: 🐛 auth changes

* chore: 🔧 improve logging and account fixes

* chore: 🔧 change footer

* chore: 🔧 remove console logs

* chore: 🔧 add spacing

* fix: 🐛 final changes
2020-05-19 07:50:16 +02:00

31 lines
1.2 KiB
JavaScript

/* eslint @typescript-eslint/no-var-requires: 0 */
const withBundleAnalyzer = require('@next/bundle-analyzer')({
enabled: process.env.ANALYZE === 'true',
});
module.exports = withBundleAnalyzer({
poweredByHeader: false,
assetPrefix: process.env.BASE_PATH || '',
serverRuntimeConfig: {
nodeEnv: process.env.NODE_ENV || 'development',
logLevel: process.env.LOG_LEVEL || 'info',
hodlKey: process.env.HODL_KEY || '',
cookiePath: process.env.COOKIE_PATH || '',
lnServerUrl: process.env.SSO_SERVER_URL || '',
lnCertPath: process.env.SSO_CERT_PATH || '',
macaroonPath: process.env.SSO_MACAROON_PATH || '',
accountConfigPath: process.env.ACCOUNT_CONFIG_PATH || '',
},
publicRuntimeConfig: {
nodeEnv: process.env.NODE_ENV || 'development',
apiUrl: `${process.env.BASE_PATH || ''}/api/v1`,
apiBaseUrl: `${process.env.API_BASE_URL || ''}/api/v1`,
basePath: process.env.BASE_PATH || '',
npmVersion: process.env.npm_package_version || '0.0.0',
defaultTheme: process.env.THEME || 'dark',
defaultCurrency: process.env.CURRENCY || 'sat',
fetchPrices: process.env.FETCH_PRICES === 'true' ? true : false,
fetchFees: process.env.FETCH_FEES === 'true' ? true : false,
},
});