Compare commits

..

1 Commits

Author SHA1 Message Date
sriram veeraghanta 5f5ab2b75d fix: moving nginx to caddy 2025-03-09 16:19:09 +05:30
34 changed files with 84 additions and 93 deletions
+1 -3
View File
@@ -1,8 +1,6 @@
{
"name": "admin",
"description": "Admin UI for Plane",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"private": true,
"scripts": {
"dev": "turbo run develop",
+1 -4
View File
@@ -1,7 +1,4 @@
{
"name": "plane-api",
"version": "0.25.1",
"license": "AGPL-3.0",
"private": true,
"description": "API server powering Plane's backend"
"version": "0.25.0"
}
+2 -8
View File
@@ -80,7 +80,6 @@ class IssueSerializer(BaseSerializer):
data["assignees"] = ProjectMember.objects.filter(
project_id=self.context.get("project_id"),
is_active=True,
role__gte=15,
member_id__in=data["assignees"],
).values_list("member_id", flat=True)
@@ -159,13 +158,8 @@ class IssueSerializer(BaseSerializer):
pass
else:
try:
# Then assign it to default assignee, if it is a valid assignee
if default_assignee_id is not None and ProjectMember.objects.filter(
member_id=default_assignee_id,
project_id=project_id,
role__gte=15,
is_active=True
).exists():
# Then assign it to default assignee
if default_assignee_id is not None:
IssueAssignee.objects.create(
assignee_id=default_assignee_id,
issue=issue,
+8 -27
View File
@@ -36,7 +36,6 @@ from plane.db.models import (
State,
IssueVersion,
IssueDescriptionVersion,
ProjectMember,
)
@@ -120,17 +119,6 @@ class IssueCreateSerializer(BaseSerializer):
raise serializers.ValidationError("Start date cannot exceed target date")
return data
def get_valid_assignees(self, assignees, project_id):
if not assignees:
return []
return ProjectMember.objects.filter(
project_id=project_id,
role__gte=15,
is_active=True,
member_id__in=assignees
).values_list('member_id', flat=True)
def create(self, validated_data):
assignees = validated_data.pop("assignee_ids", None)
labels = validated_data.pop("label_ids", None)
@@ -146,33 +134,27 @@ class IssueCreateSerializer(BaseSerializer):
created_by_id = issue.created_by_id
updated_by_id = issue.updated_by_id
valid_assignee_ids = self.get_valid_assignees(assignees, project_id)
if valid_assignee_ids is not None and len(valid_assignee_ids):
if assignees is not None and len(assignees):
try:
IssueAssignee.objects.bulk_create(
[
IssueAssignee(
assignee_id=user_id,
assignee=user,
issue=issue,
project_id=project_id,
workspace_id=workspace_id,
created_by_id=created_by_id,
updated_by_id=updated_by_id,
)
for user_id in valid_assignee_ids
for user in assignees
],
batch_size=10,
)
except IntegrityError:
pass
else:
# Then assign it to default assignee, if it is a valid assignee
if default_assignee_id is not None and ProjectMember.objects.filter(
member_id=default_assignee_id,
project_id=project_id,
role__gte=15,
is_active=True
).exists():
# Then assign it to default assignee
if default_assignee_id is not None:
try:
IssueAssignee.objects.create(
assignee_id=default_assignee_id,
@@ -216,21 +198,20 @@ class IssueCreateSerializer(BaseSerializer):
created_by_id = instance.created_by_id
updated_by_id = instance.updated_by_id
valid_assignee_ids = self.get_valid_assignees(assignees, project_id)
if valid_assignee_ids is not None:
if assignees is not None:
IssueAssignee.objects.filter(issue=instance).delete()
try:
IssueAssignee.objects.bulk_create(
[
IssueAssignee(
assignee_id=user_id,
assignee=user,
issue=instance,
project_id=project_id,
workspace_id=workspace_id,
created_by_id=created_by_id,
updated_by_id=updated_by_id,
)
for user_id in valid_assignee_ids
for user in assignees
],
batch_size=10,
ignore_conflicts=True,
+3 -3
View File
@@ -1,8 +1,7 @@
{
"name": "live",
"version": "0.25.1",
"license": "AGPL-3.0",
"description": "A realtime collaborative server powers Plane's rich text editor",
"version": "0.25.0",
"description": "",
"main": "./src/server.ts",
"private": true,
"type": "module",
@@ -15,6 +14,7 @@
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"@hocuspocus/extension-database": "^2.15.0",
"@hocuspocus/extension-logger": "^2.15.0",
+3 -4
View File
@@ -1,8 +1,6 @@
{
"name": "plane",
"description": "Open-source project management that unlocks customer value",
"repository": "https://github.com/makeplane/plane.git",
"version": "0.25.1",
"version": "0.25.0",
"license": "AGPL-3.0",
"private": true,
"workspaces": [
@@ -30,5 +28,6 @@
"nanoid": "3.3.8",
"esbuild": "0.25.0"
},
"packageManager": "yarn@1.22.22"
"packageManager": "yarn@1.22.22",
"name": "plane"
}
+2 -3
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/constants",
"version": "0.25.1",
"version": "0.25.0",
"private": true,
"main": "./src/index.ts",
"license": "AGPL-3.0"
"main": "./src/index.ts"
}
+1 -2
View File
@@ -1,8 +1,7 @@
{
"name": "@plane/editor",
"version": "0.25.1",
"version": "0.25.0",
"description": "Core Editor that powers Plane",
"license": "AGPL-3.0",
"private": true,
"main": "./dist/index.mjs",
"module": "./dist/index.mjs",
+1 -2
View File
@@ -1,8 +1,7 @@
{
"name": "@plane/eslint-config",
"private": true,
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"files": [
"library.js",
"next.js",
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/hooks",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"description": "React hooks that are shared across multiple apps internally",
"private": true,
"main": "./dist/index.js",
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/i18n",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"description": "I18n shared across multiple apps internally",
"private": true,
"main": "./src/index.ts",
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/logger",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"description": "Logger shared across multiple apps internally",
"private": true,
"main": "./src/index.ts",
+1 -2
View File
@@ -1,8 +1,7 @@
{
"name": "@plane/propel",
"version": "0.25.1",
"version": "0.25.0",
"private": true,
"license": "AGPL-3.0",
"scripts": {
"lint": "eslint src --ext .ts,.tsx",
"lint:errors": "eslint src --ext .ts,.tsx --quiet"
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/services",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"private": true,
"main": "./src/index.ts",
"scripts": {
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/shared-state",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"description": "Shared state shared across multiple apps internally",
"private": true,
"main": "./src/index.ts",
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/tailwind-config",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"description": "common tailwind configuration across monorepo",
"main": "tailwind.config.js",
"private": true,
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/types",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"private": true,
"types": "./src/index.d.ts",
"main": "./src/index.d.ts"
+1 -2
View File
@@ -1,7 +1,6 @@
{
"name": "@plane/typescript-config",
"version": "0.25.1",
"license": "AGPL-3.0",
"version": "0.25.0",
"private": true,
"files": [
"base.json",
+2 -2
View File
@@ -2,12 +2,12 @@
"name": "@plane/ui",
"description": "UI components shared across multiple apps internally",
"private": true,
"version": "0.25.1",
"version": "0.25.0",
"main": "./dist/index.js",
"module": "./dist/index.mjs",
"types": "./dist/index.d.ts",
"sideEffects": false,
"license": "AGPL-3.0",
"license": "MIT",
"files": [
"dist/**"
],
+1 -2
View File
@@ -1,8 +1,7 @@
{
"name": "@plane/utils",
"version": "0.25.1",
"version": "0.25.0",
"description": "Helper functions shared across multiple apps internally",
"license": "AGPL-3.0",
"private": true,
"main": "./dist/index.js",
"module": "./dist/index.mjs",
@@ -1,9 +1,9 @@
FROM nginx:1.25.0-alpine
RUN rm /etc/nginx/conf.d/default.conf
COPY nginx.conf.dev /etc/nginx/nginx.conf.template
COPY nginx/nginx.conf.dev /etc/nginx/nginx.conf.template
COPY ./env.sh /docker-entrypoint.sh
COPY nginx/env.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
# Update all environment variables
+2 -2
View File
@@ -1,9 +1,9 @@
FROM nginx:1.25.0-alpine
RUN rm /etc/nginx/conf.d/default.conf
COPY nginx.conf.template /etc/nginx/nginx.conf.template
COPY nginx/nginx.conf.template /etc/nginx/nginx.conf.template
COPY ./env.sh /docker-entrypoint.sh
COPY nginx/env.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
# Update all environment variables
+1
View File
@@ -0,0 +1 @@
nginx.conf.template
+39
View File
@@ -0,0 +1,39 @@
(plane_proxy) {
request_body {
max_size {$FILE_SIZE_LIMIT}
}
reverse_proxy /spaces/* space:3000
reverse_proxy /god-mode/* admin:3000
reverse_proxy /api/* api:8000
reverse_proxy /auth/* api:8000
reverse_proxy /live/* live:3000
reverse_proxy /{$BUCKET_NAME} plane-minio:9000
reverse_proxy /{$BUCKET_NAME}/* plane-minio:9000
reverse_proxy /* web:3000
}
{
email {$CERT_EMAIL:admin@example.com}
acme_ca {$CERT_ACME_CA}
{$CERT_ACME_DNS}
servers {
timeouts {
read_body 600s
read_header 30s
write 600s
idle 600s
}
max_header_size 25MB
client_ip_headers X-Forwarded-For X-Real-IP
trusted_proxies static {$TRUSTED_PROXIES:0.0.0.0/0}
}
log {
output {$LOG_OUTPUT:stdout}
level {$LOG_LEVEL:INFO}
}
}
{$SITE_ADDRESS} {
import plane_proxy
}
View File
+1 -2
View File
@@ -1,8 +1,7 @@
{
"name": "space",
"version": "0.25.1",
"version": "0.25.0",
"private": true,
"license": "AGPL-3.0",
"scripts": {
"dev": "turbo run develop",
"develop": "next dev -p 3002",
@@ -66,7 +66,7 @@ export const IssueAttachmentsListItem: FC<TIssueAttachmentsListItem> = observer(
</div>
<div className="flex items-center gap-3">
{attachment?.created_by && (
{attachment?.updated_by && (
<>
<Tooltip
isMobile={isMobile}
+2 -6
View File
@@ -179,9 +179,7 @@ export class CycleStore implements ICycleStore {
const endDate = getDate(c.end_date);
const hasEndDatePassed = endDate && isPast(endDate);
const isEndDateToday = endDate && isToday(endDate);
return (
c.project_id === projectId && ((hasEndDatePassed && !isEndDateToday) || c.status?.toLowerCase() === "completed")
);
return c.project_id === projectId && hasEndDatePassed && !isEndDateToday && !c?.archived_at;
});
completedCycles = sortBy(completedCycles, [(c) => c.sort_order]);
const completedCycleIds = completedCycles.map((c) => c.id);
@@ -197,9 +195,7 @@ export class CycleStore implements ICycleStore {
let incompleteCycles = Object.values(this.cycleMap ?? {}).filter((c) => {
const endDate = getDate(c.end_date);
const hasEndDatePassed = endDate && isPast(endDate);
return (
c.project_id === projectId && !hasEndDatePassed && !c?.archived_at && c.status?.toLowerCase() !== "completed"
);
return c.project_id === projectId && !hasEndDatePassed && !c?.archived_at;
});
incompleteCycles = sortBy(incompleteCycles, [(c) => c.sort_order]);
const incompleteCycleIds = incompleteCycles.map((c) => c.id);
+1
View File
@@ -425,6 +425,7 @@ export class ModulesStore implements IModuleStore {
set(this.moduleMap, [moduleId], { ...originalModuleDetails, ...data });
});
const response = await this.moduleService.patchModule(workspaceSlug, projectId, moduleId, data);
this.fetchModuleDetails(workspaceSlug, projectId, moduleId);
return response;
} catch (error) {
console.error("Failed to update module in module store", error);
+1 -2
View File
@@ -1,8 +1,7 @@
{
"name": "web",
"version": "0.25.1",
"version": "0.25.0",
"private": true,
"license": "AGPL-3.0",
"scripts": {
"dev": "turbo run develop",
"develop": "next dev --port 3000",