Skip to content

Commit

Permalink
Merge pull request #1939 from ever-co/develop
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
evereq authored Dec 2, 2023
2 parents 6a5d362 + f1e32bb commit aae9491
Show file tree
Hide file tree
Showing 12 changed files with 1,152 additions and 30 deletions.
6 changes: 6 additions & 0 deletions .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@
"cloudinary",
"clsx",
"clsxm",
"opentelemetry",
"otlp",
"commitlint",
"greenkeeper",
"classpath",
"tsbuildinfo",
"sentryclirc",
"compodoc",
"consectetur",
"dolor",
Expand Down
10 changes: 8 additions & 2 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,26 @@ Jenkinsfile

**/.next
**/build
**/node_modules/*
**/dist
**/out

**/*.log

**/.vscode

**/.env
**/.env.local
**/.env*.local
**/.env*.sample
apps/**/.env
apps/**/.env.local
apps/**/.env*.local
apps/**/.env*.sample

fly.toml

node_modules

**/node_modules/*
apps/mobile/node_modules
apps/desktop/node_modules
apps/extensions/node_modules
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Web Build & Deploy DEV
name: Web Build & Vercel Deploy DEV
on:
push:
branches:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Web Build & Deploy PROD
name: Web Build & Vercel Deploy PROD
on:
push:
branches:
Expand Down
2 changes: 1 addition & 1 deletion apps/mobile/app/services/client/requests/features/smtp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export const smtpConfiguration: () => I_SMTPRequest = () => ({
fromAddress: SMTP_FROM_ADDRESS || '',
host: SMTP_HOST || '',
port: parseInt(SMTP_PORT, 10) || 0,
secure: SMTP_SECURE === 'true' ? true : false,
secure: SMTP_SECURE === 'true',
username: SMTP_USERNAME || '',
password: SMTP_PASSWORD || ''
});
Expand Down
7 changes: 4 additions & 3 deletions apps/web/app/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,10 @@ export const RECAPTCHA_SITE_KEY = process.env.NEXT_PUBLIC_CAPTCHA_SITE_KEY;
export const RECAPTCHA_SECRET_KEY = process.env.CAPTCHA_SECRET_KEY;

export const GAUZY_API_SERVER_URL = process.env.GAUZY_API_SERVER_URL || 'https://api.gauzy.co/api';
export const INVITE_CALLBACK_URL = process.env.INVITE_CALLBACK_URL;

export const INVITE_CALLBACK_URL = process.env.INVITE_CALLBACK_URL || 'https://app.ever.team/auth/passcode';
export const INVITE_CALLBACK_PATH = '/auth/passcode';
export const VERIFY_EMAIL_CALLBACK_URL = process.env.VERIFY_EMAIL_CALLBACK_URL;
export const VERIFY_EMAIL_CALLBACK_URL = process.env.VERIFY_EMAIL_CALLBACK_URL || 'https://app.ever.team/verify-email';
export const VERIFY_EMAIL_CALLBACK_PATH = '/verify-email';
export const GA_MEASUREMENT_ID = process.env.NEXT_PUBLIC_GA_MEASUREMENT_ID;

Expand Down Expand Up @@ -73,7 +74,7 @@ export const MEET_JWT_TOKEN_COOKIE_NAME = 'meet-jwt-session';

// BOARD board
export const BOARD_APP_DOMAIN = process.env.NEXT_PUBLIC_BOARD_APP_DOMAIN || 'https://board.ever.team';
export const BOARD_BACKEND_POST_URL = process.env.NEXT_PUBLIC_BOARD_BACKEND_POST_URL;
export const BOARD_BACKEND_POST_URL = process.env.NEXT_PUBLIC_BOARD_BACKEND_POST_URL || 'https://jsonboard.ever.team/api/v2/post/';
export const BOARD_FIREBASE_CONFIG = process.env.NEXT_PUBLIC_BOARD_FIREBASE_CONFIG;

// Jitsu
Expand Down
7 changes: 4 additions & 3 deletions apps/web/app/helpers/validations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,9 @@ export const authFormValidate = (keys: (keyof IRegisterDataAPI)[], values: IRegi
}
break;
case 'recaptcha':
if(RECAPTCHA_SITE_KEY) {
if (RECAPTCHA_SITE_KEY) {
if (!values['recaptcha'] || values['recaptcha'].trim().length < 2) {
err['recaptcha'] =
'Please check the ReCaptcha checkbox before continue';
err['recaptcha'] = 'Please check the ReCaptcha checkbox before continue';
}
}
break;
Expand Down Expand Up @@ -90,6 +89,8 @@ export function validateForm<T extends Ks>(keys: (keyof T)[], data: T) {
export function validSMTPConfig() {
const SMTPConfig = smtpConfiguration();

console.log(`SMTP Config: ${JSON.stringify(SMTPConfig)}`);

const keys = Object.keys(SMTPConfig) as (keyof I_SMTPRequest)[];

if (keys.some((key) => SMTPConfig[key] === null || SMTPConfig[key] === undefined)) {
Expand Down
3 changes: 3 additions & 0 deletions apps/web/app/services/server/requests/smtp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import { serverFetch } from '../fetch';

export function createTenantSmtpRequest({ tenantId, access_token }: { tenantId: string; access_token: string }) {
const config = smtpConfiguration();

console.log(`SMTP Config: ${JSON.stringify(config)}`);

return serverFetch<I_SMTP>({
path: '/smtp',
method: 'POST',
Expand Down
23 changes: 13 additions & 10 deletions apps/web/next.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
/* eslint-disable @typescript-eslint/no-var-requires */
const path = require('path');

console.log(`GAUZY_API_SERVER_URL: ${process.env.GAUZY_API_SERVER_URL}`);
console.log(`NEXT_PUBLIC_GAUZY_API_SERVER_URL: ${process.env.NEXT_PUBLIC_GAUZY_API_SERVER_URL}`);

// eslint-disable-next-line @typescript-eslint/no-var-requires
/** @type {import('next').NextConfig} */
const nextConfig = {
Expand Down Expand Up @@ -29,19 +32,19 @@ const nextConfig = {
}, // Optional build-time configuration options
sentry: {
// For all available options, see: https://docs.sentry.io/platforms/javascript/guides/nextjs/manual-setup/

// Upload a larger set of source maps for prettier stack traces (increases build time)
widenClientFileUpload: true,

// Transpiles SDK to be compatible with IE11 (increases bundle size)
transpileClientSDK: true,

// Routes browser requests to Sentry through a Next.js rewrite to circumvent ad-blockers (increases server load)
tunnelRoute: '/monitoring',

// Hides source maps from generated client bundles
hideSourceMaps: true,

// Automatically tree-shake Sentry logger statements to reduce bundle size
disableLogger: true
}
Expand All @@ -50,18 +53,18 @@ const nextConfig = {
// Injected content via Sentry wizard below
const { withSentryConfig } = require('@sentry/nextjs');

const sentryWebpackPluginOptions = {
org: process.env.SENTRY_ORG,
project: process.env.SENTRY_PROJECT,
const sentryWebpackPluginOptions = {
org: process.env.SENTRY_ORG || 'ever-co',
project: process.env.SENTRY_PROJECT || 'ever-teams-web',

// An auth token is required for uploading source maps.
authToken: process.env.SENTRY_AUTH_TOKEN,

silent: true, // Suppresses all logs

dryRun: process.env.NODE_ENV !== "production"
// Additional config options for the Sentry Webpack plugin.

// Additional config options for the Sentry Webpack plugin.
// Keep in mind that https://github.com/getsentry/sentry-webpack-plugin#options.
};

Expand Down
8 changes: 7 additions & 1 deletion apps/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,13 @@
"string-to-color": "^2.2.2",
"tailwind-merge": "^1.14.0",
"tailwindcss": "^3.1.8",
"tailwindcss-animate": "^1.0.6"
"tailwindcss-animate": "^1.0.6",
"@opentelemetry/api": "^1.7.0",
"@opentelemetry/sdk-node": "^0.45.1",
"@opentelemetry/auto-instrumentations-node": "^0.40.1",
"@opentelemetry/exporter-trace-otlp-http": "^0.45.1",
"@opentelemetry/resources": "^1.18.1",
"@opentelemetry/semantic-conventions": "^1.18.1"
},
"devDependencies": {
"@tailwindcss/typography": "^0.5.9",
Expand Down
6 changes: 6 additions & 0 deletions apps/web/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,12 @@ MyApp.getInitialProps = async ({ Component, ctx }: { Component: NextPage<AppProp
const jitsuWriteKey = process.env.NEXT_PUBLIC_JITSU_BROWSER_WRITE_KEY;

const jitsuConf = jitsuConfiguration();

console.log(`Jitsu Host: ${jitsuHost}`);
console.log(`Jitsu Write Key: ${jitsuWriteKey}`);

console.log(`Jitsu Configuration: ${JSON.stringify(jitsuConf)}`);

// Call the static method getInitialProps
// of the page component if it exists
let pageProps = {};
Expand Down
Loading

0 comments on commit aae9491

Please sign in to comment.