Skip to content

Worklenz: 高效团队的全方位项目管理工具

Published:

原文链接


Worklenz Logo
Worklenz

Task Management | Time Tracking | Analytics | Resource Management | Project Templates

Worklenz

Worklenz is a project management tool designed to help organizations improve their efficiency. It provides a comprehensive solution for managing projects, tasks, and collaboration within teams.

Features

Tech Stack

This repository contains the frontend and backend code for Worklenz.

Requirements

Getting Started

These instructions will help you set up and run the Worklenz project on your local machine for development and testing purposes.

Prerequisites

Option 1: Manual Installation

  1. Clone the repository
git clone https://github.com/Worklenz/worklenz.git
cd worklenz
  1. Set up environment variables

    • Copy the example environment files
    cp .env.example .env
    cp worklenz-backend/.env.example worklenz-backend/.env
    
    • Update the environment variables with your configuration
  2. Install dependencies

# Install backend dependencies
cd worklenz-backend
npm install

# Install frontend dependencies
cd ../worklenz-frontend
npm install
  1. Set up the database
# Create a PostgreSQL database named worklenz_db
cd worklenz-backend

# Execute the SQL setup files in the correct order
psql -U your_username -d worklenz_db -f database/sql/0_extensions.sql
psql -U your_username -d worklenz_db -f database/sql/1_tables.sql
psql -U your_username -d worklenz_db -f database/sql/indexes.sql
psql -U your_username -d worklenz_db -f database/sql/4_functions.sql
psql -U your_username -d worklenz_db -f database/sql/triggers.sql
psql -U your_username -d worklenz_db -f database/sql/3_views.sql
psql -U your_username -d worklenz_db -f database/sql/2_dml.sql
psql -U your_username -d worklenz_db -f database/sql/5_database_user.sql
  1. Start the development servers
# In one terminal, start the backend
cd worklenz-backend
npm run dev

# In another terminal, start the frontend
cd worklenz-frontend
npm run dev
  1. Access the application at http://localhost:5000

Option 2: Docker Setup

The project includes a fully configured Docker setup with:

  1. Clone the repository:
git clone https://github.com/Worklenz/worklenz.git
cd worklenz
  1. Start the Docker containers (choose one option):

Using Docker Compose directly

docker-compose up -d
  1. The application will be available at:

  2. To stop the services:

docker-compose down

Configuration

Environment Variables

Worklenz requires several environment variables to be configured for proper operation. These include:

Please refer to the .env.example files for a full list of required variables.

MinIO Integration

The project uses MinIO as an S3-compatible object storage service, which provides an open-source alternative to AWS S3 for development and production.

Security Considerations

For production deployments:

  1. Use strong, unique passwords and keys for all services
  2. Do not commit .env files to version control
  3. Use a production-grade PostgreSQL setup with proper backup procedures
  4. Enable HTTPS for all public endpoints
  5. Review and update dependencies regularly

Contributing

We welcome contributions from the community! If you’d like to contribute, please follow our contributing guidelines.

Security

If you believe you have found a security vulnerability in Worklenz, we encourage you to responsibly disclose this and not open a public issue. We will investigate all legitimate reports.

Email [email protected] to disclose any security vulnerabilities.

License

This project is licensed under the MIT License.

Screenshots

Worklenz task views

Worklenz time tracking

Worklenz analytics

Worklenz scheduler

Worklenz templates

Contributing

We welcome contributions from the community! If you’d like to contribute, please follow our contributing guidelines.

License

Worklenz is open source and released under the GNU Affero General Public License Version 3 (AGPLv3).

By contributing to Worklenz, you agree that your contributions will be licensed under its AGPL.

Worklenz React

This repository contains the React version of Worklenz with a Docker setup for easy development and deployment.

Getting Started with Docker

The project includes a fully configured Docker setup with:

Prerequisites

Quick Start

  1. Clone the repository:
git clone https://github.com/Worklenz/worklenz.git
cd worklenz
  1. Start the Docker containers (choose one option):

Option 1: Using the provided scripts (easiest)

Option 2: Using Docker Compose directly

docker-compose up -d
  1. The application will be available at:

  2. To stop the services (choose one option):

Option 1: Using the provided scripts

Option 2: Using Docker Compose directly

docker-compose down

MinIO Integration

The project uses MinIO as an S3-compatible object storage service, which provides an open-source alternative to AWS S3 for development and production.

Working with MinIO

MinIO provides an S3-compatible API, so any code that works with S3 will work with MinIO by simply changing the endpoint URL. The backend has been configured to use MinIO by default, with no additional configuration required.

Backend Storage Configuration

The backend is pre-configured to use MinIO with the following settings:

// S3 credentials with MinIO defaults
export const REGION = process.env.AWS_REGION || "us-east-1";
export const BUCKET = process.env.AWS_BUCKET || "worklenz-bucket";
export const S3_URL = process.env.S3_URL || "http://minio:9000/worklenz-bucket";
export const S3_ACCESS_KEY_ID = process.env.AWS_ACCESS_KEY_ID || "minioadmin";
export const S3_SECRET_ACCESS_KEY = process.env.AWS_SECRET_ACCESS_KEY || "minioadmin";

The S3 client is initialized with special MinIO configuration:

const s3Client = new S3Client({
  region: REGION,
  credentials: {
    accessKeyId: S3_ACCESS_KEY_ID || "",
    secretAccessKey: S3_SECRET_ACCESS_KEY || "",
  },
  endpoint: getEndpointFromUrl(), // Extracts endpoint from S3_URL
  forcePathStyle: true, // Required for MinIO
});

Environment Configuration

The .env file includes the necessary configuration for using MinIO:

STORAGE_PROVIDER=s3
AWS_REGION=us-east-1
AWS_BUCKET=worklenz-bucket
S3_ACCESS_KEY_ID=minioadmin
S3_SECRET_ACCESS_KEY=minioadmin
S3_URL=http://minio:9000

When the backend service starts, it will use these environment variables to connect to MinIO for file storage.

Development

For development, you can use the provided Docker setup which includes all necessary dependencies. The code will be running inside containers, but you can still edit files locally and see changes reflected in real-time.

Production Deployment

For production deployment:

  1. Update the .env file with production settings
  2. Build custom Docker images or use the provided ones
  3. Deploy using Docker Compose or a container orchestration platform like Kubernetes

For MinIO in production, consider:


Previous Post
The largest collection of free stuff on the internet!
Next Post
Kuma Mieru:基于 Next.js 15 的 Uptime Kuma 监控仪表盘