From 75fa1231a8a793ed8ee6d7ed7205184088797701 Mon Sep 17 00:00:00 2001 From: Muneeb-Ventures Date: Fri, 5 Apr 2024 10:00:01 +0530 Subject: [PATCH 1/4] =?UTF-8?q?=E2=9A=A1(enhancement)[8949]=20Editing=20in?= =?UTF-8?q?vite=20message?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../images/parabol-ubi/dockerfiles/DockerFile | 29 +++++++++++++++++++ .../server/email/teamInviteEmailCreator.tsx | 4 +-- 2 files changed, 31 insertions(+), 2 deletions(-) create mode 100644 docker/images/parabol-ubi/dockerfiles/DockerFile diff --git a/docker/images/parabol-ubi/dockerfiles/DockerFile b/docker/images/parabol-ubi/dockerfiles/DockerFile new file mode 100644 index 00000000000..94c244bc860 --- /dev/null +++ b/docker/images/parabol-ubi/dockerfiles/DockerFile @@ -0,0 +1,29 @@ +ARG _NODE_VERSION=${20.11.0} +FROM node:20.11.0-bookworm-slim as base + +ENV HOME=/home/node \ + USER=node + +ENV NPM_CONFIG_PREFIX=/home/node/.npm-global +ENV PORT=3000 + +COPY --chown=node --chmod=755 docker/images/parabol-ubi/entrypoints/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh +COPY --chown=node docker/images/parabol-ubi/tools/ip-to-server_id ${HOME}/tools/ip-to-server_id + +# Required for pushToCDN to work with FILE_STORE_PROVIDER set to 'local' +RUN mkdir -p ${HOME}/parabol/self-hosted && \ + chown node:node ${HOME}/parabol/self-hosted + +COPY --chown=node .env.example ${HOME}/parabol/.env.example + +# The application requires a yarn.lock file on the root folder to identify it +COPY --chown=node yarn.lock ${HOME}/parabol/yarn.lock +COPY --chown=node build ${HOME}/parabol/build +COPY --chown=node dist ${HOME}/parabol/dist + +WORKDIR ${HOME}/parabol/ + +USER node +EXPOSE ${PORT} + +ENTRYPOINT ["docker-entrypoint.sh"] diff --git a/packages/server/email/teamInviteEmailCreator.tsx b/packages/server/email/teamInviteEmailCreator.tsx index a625e55d73a..c01562bee22 100644 --- a/packages/server/email/teamInviteEmailCreator.tsx +++ b/packages/server/email/teamInviteEmailCreator.tsx @@ -3,7 +3,7 @@ import TeamInvite, {TeamInviteProps} from 'parabol-client/modules/email/componen import {headCSS} from 'parabol-client/modules/email/styles' import React from 'react' -const subject = 'You’ve been invited to Parabol' +const subject = (inviterEmail: string) => `${inviterEmail} has invited you to Parabol` const teamInviteText = (props: TeamInviteProps) => { const {inviteeName, inviteeEmail, inviterName, inviterEmail, inviteLink, teamName} = props @@ -22,7 +22,7 @@ The Parabol Product Team } export default (props: TeamInviteProps) => ({ - subject, + subject: subject(props.inviterEmail), body: teamInviteText(props), html: Oy.renderTemplate(, { headCSS, From 750ffadc3b7a83c06170b7950ede7f1bec84000d Mon Sep 17 00:00:00 2001 From: Muneeb-Ventures Date: Fri, 5 Apr 2024 10:04:16 +0530 Subject: [PATCH 2/4] adding return type --- packages/server/email/teamInviteEmailCreator.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/server/email/teamInviteEmailCreator.tsx b/packages/server/email/teamInviteEmailCreator.tsx index c01562bee22..acb3539c787 100644 --- a/packages/server/email/teamInviteEmailCreator.tsx +++ b/packages/server/email/teamInviteEmailCreator.tsx @@ -3,7 +3,7 @@ import TeamInvite, {TeamInviteProps} from 'parabol-client/modules/email/componen import {headCSS} from 'parabol-client/modules/email/styles' import React from 'react' -const subject = (inviterEmail: string) => `${inviterEmail} has invited you to Parabol` +const subject = (inviterEmail: string) : string => `${inviterEmail} has invited you to Parabol` const teamInviteText = (props: TeamInviteProps) => { const {inviteeName, inviteeEmail, inviterName, inviterEmail, inviteLink, teamName} = props From 51d86653775378301d19d2d2f1f859a6aa37bf9a Mon Sep 17 00:00:00 2001 From: Mohd Muneeb Date: Fri, 5 Apr 2024 10:14:06 +0530 Subject: [PATCH 3/4] :zap: (refactor) Edited the inviter subject --- .../images/parabol-ubi/dockerfiles/DockerFile | 29 ------------------- 1 file changed, 29 deletions(-) delete mode 100644 docker/images/parabol-ubi/dockerfiles/DockerFile diff --git a/docker/images/parabol-ubi/dockerfiles/DockerFile b/docker/images/parabol-ubi/dockerfiles/DockerFile deleted file mode 100644 index 94c244bc860..00000000000 --- a/docker/images/parabol-ubi/dockerfiles/DockerFile +++ /dev/null @@ -1,29 +0,0 @@ -ARG _NODE_VERSION=${20.11.0} -FROM node:20.11.0-bookworm-slim as base - -ENV HOME=/home/node \ - USER=node - -ENV NPM_CONFIG_PREFIX=/home/node/.npm-global -ENV PORT=3000 - -COPY --chown=node --chmod=755 docker/images/parabol-ubi/entrypoints/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh -COPY --chown=node docker/images/parabol-ubi/tools/ip-to-server_id ${HOME}/tools/ip-to-server_id - -# Required for pushToCDN to work with FILE_STORE_PROVIDER set to 'local' -RUN mkdir -p ${HOME}/parabol/self-hosted && \ - chown node:node ${HOME}/parabol/self-hosted - -COPY --chown=node .env.example ${HOME}/parabol/.env.example - -# The application requires a yarn.lock file on the root folder to identify it -COPY --chown=node yarn.lock ${HOME}/parabol/yarn.lock -COPY --chown=node build ${HOME}/parabol/build -COPY --chown=node dist ${HOME}/parabol/dist - -WORKDIR ${HOME}/parabol/ - -USER node -EXPOSE ${PORT} - -ENTRYPOINT ["docker-entrypoint.sh"] From 84d53d40d57c7d6a6dd5c66c4506531ab51b53a3 Mon Sep 17 00:00:00 2001 From: Mohd-Muneeb Date: Mon, 8 Apr 2024 14:41:37 +0530 Subject: [PATCH 4/4] (refactor) [text edit] changing invitation subject to include inviter name --- packages/server/email/teamInviteEmailCreator.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/server/email/teamInviteEmailCreator.tsx b/packages/server/email/teamInviteEmailCreator.tsx index acb3539c787..98243b834e8 100644 --- a/packages/server/email/teamInviteEmailCreator.tsx +++ b/packages/server/email/teamInviteEmailCreator.tsx @@ -3,7 +3,7 @@ import TeamInvite, {TeamInviteProps} from 'parabol-client/modules/email/componen import {headCSS} from 'parabol-client/modules/email/styles' import React from 'react' -const subject = (inviterEmail: string) : string => `${inviterEmail} has invited you to Parabol` +const subject = (inviterName: string) : string => `${inviterName} has invited you to Parabol` const teamInviteText = (props: TeamInviteProps) => { const {inviteeName, inviteeEmail, inviterName, inviterEmail, inviteLink, teamName} = props @@ -22,7 +22,7 @@ The Parabol Product Team } export default (props: TeamInviteProps) => ({ - subject: subject(props.inviterEmail), + subject: subject(props.inviterName), body: teamInviteText(props), html: Oy.renderTemplate(, { headCSS,