Skip to content

chainorders/upwood

Β 
Β 

Repository files navigation

Upwood Concordium RWA Platform

A comprehensive blockchain-based Real World Asset management system on Concordium blockchain, specializing in forest project tokenization and environmental asset management.

🌟 Project Overview

Upwood's Concordium RWA (Real World Asset) platform is designed to tokenize and manage forest projects, enabling transparent investment, trading, and yield distribution of environmental assets. The system provides a complete ecosystem for forest project bonds, carbon credit tokenization, P2P trading, and investor rewards.

Key Features

  • 🌳 Forest Project Tokenization - Represent forest projects as blockchain assets
  • πŸƒ Carbon Credit Management - Tokenize and trade carbon credits on-chain
  • πŸ’° Investment Fund Management - Bond and tranche-based forest project funding
  • πŸ”„ P2P Trading Platform - Direct trading of environmental assets
  • 🏦 Yield Distribution - Automated reward distribution to investors
  • πŸ” Identity & Compliance - Comprehensive access control and regulatory compliance
  • ⚑ Multi-Workspace Architecture - Modular development environment with specialized containers

πŸ—οΈ Architecture Overview

The platform consists of five main workspaces, each optimized for specific development tasks:

concordium-rwa/
β”œβ”€β”€ πŸ“¦ contracts/           # Concordium Smart Contracts (Rust)
β”œβ”€β”€ πŸ”§ backend/            # Event Listener & API Services (Rust)
β”œβ”€β”€ 🎨 frontend-app/       # User Interface (React + Vite)
β”œβ”€β”€ ☁️  cdk-deployment/     # AWS Infrastructure (TypeScript + CDK)
└── πŸ“± frontend-dapp/      # Legacy DApp Interface (React)

πŸš€ Quick Start

Repository Setup

git clone [email protected]:chainorders/concordium-rwa.git
cd concordium-rwa
git submodule update --init --recursive

Development Environment Setup

  1. Install Prerequisites

  2. Choose Your Workspace

    • Open VS Code in the repository root
    • Run Dev Containers: Reopen in a Container
    • Select your target workspace from the list
  3. Start Development

    • Each container automatically runs yarn run to show available scripts
    • Follow workspace-specific instructions below

πŸ“¦ Workspaces

πŸ”— Smart Contracts (contracts/)

Concordium blockchain smart contracts written in Rust that enable forest project tokenization, carbon credit management, P2P trading, investment fund management, and comprehensive identity & compliance systems.

πŸ“– Full Documentation

🐳 Dev Container: Open with Dev Containers: Reopen in Container β†’ Select contracts β†’ Container files: .devcontainer/contracts/

πŸ”§ Backend Services (backend/)

Rust-based backend services that process Concordium blockchain events, provide REST APIs for frontend applications, and manage data persistence using the Poem web framework and PostgreSQL databases.

πŸ“– Full Documentation

🐳 Dev Container: Open with Dev Containers: Reopen in Container β†’ Select backend β†’ Container files: .devcontainer/backend/

🎨 Frontend Application (frontend-app/)

Modern React-based user interface built with Vite and TypeScript that provides an intuitive interface for investors to browse forest projects, manage portfolios, trade carbon credits, and interact with Concordium blockchain wallets.

πŸ“– Full Documentation

🐳 Dev Container: Open with Dev Containers: Reopen in Container β†’ Select frontend-app β†’ Container files: .devcontainer/frontend-app/

☁️ AWS Infrastructure (cdk-deployment/)

AWS Cloud Development Kit (CDK) infrastructure as code using TypeScript that manages the complete cloud infrastructure including ECS services, databases, CDN, monitoring, and security configurations for production and staging environments.

πŸ“– Full Documentation

🐳 Dev Container: Open with Dev Containers: Reopen in Container β†’ Select cdk-deployment β†’ Container files: .devcontainer/cdk-deployment/

πŸ“± Legacy DApp (frontend-dapp/)

Legacy React-based decentralized application interface primarily used for contract administration, testing, and debugging. This interface serves as an administrative tool for developers and administrators for direct smart contract interaction and system testing.

πŸ“– Full Documentation

🐳 Dev Container: Open with Dev Containers: Reopen in Container β†’ Select frontend-dapp β†’ Container files: .devcontainer/frontend-dapp/

πŸ› οΈ Development Workflow

1. Contract Development

# Open contracts workspace
code . && Dev Containers: Reopen in Container β†’ contracts

# Develop and test contracts
yarn build
yarn test
yarn deploy

2. Backend Development

# Open backend workspace
code . && Dev Containers: Reopen in Container β†’ backend

# Start services
yarn debug:listener    # Terminal 1: Blockchain listener
yarn debug:contracts-api  # Terminal 2: API server

3. Frontend Development

# Open frontend workspace
code . && Dev Containers: Reopen in Container β†’ frontend-app

# Start development server
yarn dev  # Runs on http://localhost:5173

4. Infrastructure Management

# Open CDK workspace
code . && Dev Containers: Reopen in Container β†’ cdk-deployment

# Deploy to AWS
yarn deploy

πŸ”§ Advanced Configuration

Apple Silicon Development

If developing on Apple Silicon (M1/M2), update the following files:

// Change VARIANT to "bullseye" in:
// .devcontainer/contracts/devcontainer.json
// .devcontainer/backend/docker-compose.yml
// .devcontainer/frontend-dapp/devcontainer.json
{
  "build": {
    "args": {
      "VARIANT": "bullseye"  // Changed from "bookworm"
    }
  }
}

πŸ“š Additional Resources

🀝 Contributing

  1. Choose appropriate workspace for your contribution
  2. Follow workspace-specific coding standards:
    • Contracts: Rust with Concordium standards
    • Backend: Rust with Poem framework
    • Frontend: React with TypeScript
    • Infrastructure: TypeScript with AWS CDK
  3. Write comprehensive tests
  4. Update documentation as needed

🚨 Troubleshooting

Common Issues

Container won't start:

# Rebuild container
Dev Containers: Rebuild Container

# Clear Docker cache
docker system prune -a

Database connection issues:

# Rebuild backend container to reset database
Dev Containers: Rebuild Container

# Or use backend workspace database commands
# (Open backend container first)
diesel database reset

Wallet connection problems:

# Ensure wallet file exists:
ls -la .devcontainer/contracts/default_account.export

# Check wallet format and permissions

Getting Help

  • πŸ“§ Internal Team: Use internal development channels
  • πŸ› Bug Reports: Create detailed issue reports with workspace context
  • πŸ’‘ Feature Requests: Include business case and technical requirements

Built with ❀️ for sustainable forest management and environmental impact.

About

Upwood Blockchain RWA

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 64.5%
  • Rust 34.0%
  • CSS 1.1%
  • JavaScript 0.3%
  • Dockerfile 0.1%
  • Shell 0.0%