Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

πŸ₯ Prelude #29

Draft
wants to merge 143 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
143 commits
Select commit Hold shift + click to select a range
9e908ef
Proof of concept development kit
MitchellShiell Dec 22, 2024
6e88795
Proof of concept development kit mock data
MitchellShiell Dec 22, 2024
0b616e4
Basic front-end complete, need to add documentation
MitchellShiell Dec 23, 2024
4aa07eb
updated readme and documentation
MitchellShiell Dec 23, 2024
289fd82
removed es volumes
MitchellShiell Dec 23, 2024
0f59309
readme update
MitchellShiell Dec 23, 2024
db8db90
fixed typo
MitchellShiell Jan 7, 2025
bc4a7c4
basic setup
MitchellShiell Jan 14, 2025
4f63ea5
basic setup with keycloak files
MitchellShiell Jan 14, 2025
f126291
pre-seeded keycloakDb
MitchellShiell Jan 14, 2025
2029fec
pre-seeded songDb
MitchellShiell Jan 14, 2025
cc87823
updated with phaseOne and phaseTwo docker composes
MitchellShiell Jan 14, 2025
87955da
updated phaseOne and phaseTwo folders
MitchellShiell Jan 15, 2025
9129c6e
stage in root
MitchellShiell Jan 16, 2025
2869b8d
updated stage folder
Jan 18, 2025
5ae9b57
functional song swagger component
Jan 19, 2025
8470f47
functional documentation component
Jan 19, 2025
74f2c86
functional Auth with keycloak
Jan 20, 2025
9ff4f55
minor update
Jan 20, 2025
6dfc04e
updated gitignore
Jan 20, 2025
0867fa8
moved stage folder, updated docker with build context
Jan 20, 2025
d0f3ae8
temporarily removed persistentStorage folder
Jan 20, 2025
c939004
adding persistent storage back
Jan 20, 2025
bb78fd5
documentation template, CORS swagger fix, supplementary files included
Jan 21, 2025
9f07d9e
stage downloads fixed and tested
Jan 21, 2025
dc62a2b
removed nginx configs
Jan 21, 2025
110f496
added architecture diagrams
Jan 22, 2025
610e596
removed Ego logic
Jan 22, 2025
ba0d04a
reset local databases
Jan 22, 2025
9e8a06e
phaseOne fix + stage image seperation
Jan 22, 2025
51fe382
remaining tasks, fix manifest download, provide empty postgres on sta…
Jan 22, 2025
cfef0ad
manifest downloads working
Jan 22, 2025
15b7018
improved repository structure
Jan 27, 2025
947ad94
prelude PhaseOne rework
Jan 28, 2025
3805b6a
added missing dependency installation step to csv-processor service s…
Jan 29, 2025
9adf1cf
added envs to conductor, reference by scripts
Jan 29, 2025
432dfe0
merge
Jan 29, 2025
1d7816a
updated documentation within folders
Jan 29, 2025
039a949
minor fix
Jan 29, 2025
b83f29c
updated stage with banner component
Jan 29, 2025
57d0854
added phaseThree components, updated stage + compose docs
Jan 30, 2025
671af35
phaseThree, need to address 405 on study creation
Jan 30, 2025
068f376
fixed phaseOne download bug
Jan 30, 2025
89b76c2
Created CSV-processor service
Jan 31, 2025
c4dcebf
Added inline documentation
Jan 31, 2025
f90b284
minor updates to stage, fixes to compose, updates to phaseTwo service…
Jan 31, 2025
5d4c7f1
adding index mapping generation functionality to csv-processor
Jan 31, 2025
802c541
Added arranger Config generation automation
Feb 3, 2025
7220161
update .gitignore
Feb 3, 2025
8a28c27
update Elasticsearch image version
justincorrigible Feb 4, 2025
4060708
update links to reuse shared constants
justincorrigible Feb 4, 2025
96d1d8d
tabular data index + data loading fix
Feb 5, 2025
7e50c81
commented out jsonPath and Query logic for arranger config generation
Feb 7, 2025
1f80164
ES + GQL header to fieldname validations
Feb 7, 2025
b8a1e1f
minor updates
Feb 7, 2025
6ac0761
phase2 added services running, needs testing
Feb 7, 2025
5105336
updated swagger components, still needs work
Feb 12, 2025
7541ecb
added service script for lectern schema upload
Feb 12, 2025
4d48990
added service script for song uploads, analysis still needs work
Feb 12, 2025
5d1ced0
song submission
Feb 12, 2025
3a872d1
updated scripts for phase 2 and 3
Feb 14, 2025
5b61b2d
tabular data with persistent storage automation scripts
Feb 15, 2025
c043b80
lectern schema automation TODO comments
Feb 15, 2025
f9b95d7
basic lectern schema automation, csv-processor > composer, song.ts
Feb 16, 2025
91e35da
added song schema generation using inputed json file
Feb 16, 2025
ffafb38
reorganization of csv-processor into conductor and composer
Feb 17, 2025
68f1ae7
misc infra updates
justincorrigible Feb 5, 2025
cf47925
refactor of csv-processor into conductor and composer
Feb 19, 2025
fcf37f0
refactor of csv-processor into conductor and composer
Feb 19, 2025
0970c7e
arranger config generation now includes all dataTypes
Feb 19, 2025
5826de3
index name added as option on mapping command
Feb 19, 2025
4661dee
minor fixes
Feb 20, 2025
3751f5f
Merge remote-tracking branch 'refs/remotes/origin/prelude' into prelude
Feb 20, 2025
822220b
regoranization/cleanup of conductor
Feb 20, 2025
3a25b9e
updated conductor csv processoring
Feb 21, 2025
cb59163
updated make file and docker compose
Feb 21, 2025
29de0e7
updated configuration files and scripts
Feb 21, 2025
fd1ed21
logger utility for consitent logging, need to fix debug option
Feb 23, 2025
bb0cac2
improvements to logging, need to go through each example log from --h…
Feb 23, 2025
c48c169
βœ“ generate elasticSearchMapping logging
Feb 24, 2025
ea6181f
removed vestigial cliMode references
Feb 24, 2025
fe1b0e9
removed vestigial mode references
Feb 24, 2025
da5ea9a
βœ“ generateArrangerConfig logging udpated
Feb 24, 2025
b3deb21
βœ“ generateSongSchema logging udpated - TODO more intuititve fileType …
Feb 24, 2025
7a3514b
βœ“ generateLecternDictionary logging udpated - TODO log fileNames
Feb 25, 2025
bf5ac02
imporved logger.ts util with variable bolding
Feb 25, 2025
e28f63e
conductor - CSV processing refactor inline with composer, TODO testin…
Feb 25, 2025
01843d1
segmented csv-processing services into smaller files, updated logging…
Feb 25, 2025
8213c87
updated error logs TODO fix index not found error logs
Feb 25, 2025
310c55b
conductor improved error logging + added testing
Feb 26, 2025
a745306
minor update
Feb 26, 2025
fcc86c8
minor update
Feb 26, 2025
6037bc2
minor update to invalid headers logging
Feb 26, 2025
bf8e7a8
conductor upload + indexManagement commands (cleaning logs later)
Mar 3, 2025
94ad108
conductor lecternUpload functionality
Mar 3, 2025
5b3e2ba
updated help command
Mar 3, 2025
d289bbf
register lyric with lectern dictionary functionality
Mar 3, 2025
43d258d
lyric data upload functionality
Mar 3, 2025
55cb3d5
song conductor functionality
Mar 4, 2025
1d250c5
score manifest and upload commands, (not fully functional)
Mar 5, 2025
fac4add
scoreManifestUpload working
Mar 5, 2025
a5a78ab
song publication command working
Mar 5, 2025
65161c4
songScore submission command working
Mar 5, 2025
abb7503
cleanup
Mar 5, 2025
7548cc5
improved deployment & services scripts
Mar 7, 2025
56ab42c
clean up
Mar 7, 2025
1e7a0b5
stage docs component updated
Mar 8, 2025
c8ccd80
stage docs component updated
Mar 9, 2025
5331f2f
minor update
Mar 11, 2025
d20a42c
updated UIs for docs and homepage
Mar 11, 2025
9797f43
minor updates
Mar 11, 2025
4b4dc7c
minor updates
Mar 11, 2025
0dd662e
minor updates
Mar 11, 2025
0834dad
minor updates
Mar 11, 2025
fadcaed
styling update
Mar 12, 2025
af6f7a4
exploration table dropdowns update dynamically based on folder names …
Mar 12, 2025
ebf67cb
minor update, beginning phase1 testing + documentation
Mar 12, 2025
1aea6e8
pre deployment check script
Mar 12, 2025
a3e88a8
minor updates
Mar 12, 2025
8e25dce
minor updates
Mar 12, 2025
73e4e37
phase0 docs
Mar 12, 2025
15e4b6e
βœ” Overview + Support docs
Mar 12, 2025
721f0f2
tempalated guides based on doc standards found here https://docs.over…
Mar 12, 2025
f32e20e
templating and next page footer
Mar 13, 2025
2c07951
phase1 Intro and step 1
Mar 13, 2025
3e08b6c
phase1 steps 2 + 3
Mar 13, 2025
d731547
base phase1 docker compose config update
Mar 13, 2025
8d7495f
stage generic data table update
Mar 13, 2025
01037d6
minor updates
Mar 13, 2025
84d0a26
phase1 minus stage dev updates
Mar 13, 2025
e0d579c
phase2 beginning
Mar 14, 2025
685bfbf
validation and error logging fixes
Mar 17, 2025
65a71a2
dataset > dataTable, updated lectern command allow folder input rathe…
Mar 17, 2025
bb41659
working on lyric data upload
Mar 17, 2025
bccc189
minor update
Mar 17, 2025
48c371f
updated functionality to support nested arrays in arranger config gen…
Mar 18, 2025
4061b21
fixing stage issue
Mar 19, 2025
01439db
working nicely
Mar 19, 2025
95e6840
working nicely
Mar 19, 2025
592ac40
minor update
Mar 19, 2025
fbd620a
minor update
Mar 19, 2025
0db0910
phase2 documentation update
Mar 21, 2025
8dffec8
Phase 3 docs
Mar 23, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
1 change: 0 additions & 1 deletion .gitattributes

This file was deleted.

6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
.DS_Store
.env
.DS_Store
node_modules
__MACOSX
dist
116 changes: 103 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,20 +1,110 @@
platform:
PROFILE=platform docker compose --profile platform up --attach conductor
help:
@echo "================ Prelude Makefile Commands ================"
@echo ""
@echo "Conductor Development Environments:"
@echo " phase1 - Start Phase 1 development environment"
@echo " phase2 - Start Phase 2 development environment"
@echo " phase3 - Start Phase 3 development environment"
@echo " stage-dev - Start Stage development environment"
@echo ""
@echo "Conductor Deployment:"
@echo " pre-check - Run pre-deployment checks"
@echo " deploy-stage - Deploy the stage application (with pre-checks)"
@echo ""
@echo "Conductor Data Loading and Management:"
@echo " clean-data - Remove all documents from Elasticsearch (preserves index structure)"
@echo ""
@echo "Conductor System Management:"
@echo " down - Gracefully shutdown all containers"
@echo " reset - DANGER: Remove all containers and volumes (DATA LOSS)"
@echo ""
@echo "Composer Configuration Generation:"
@echo " generate-phase-one-configs - Generate Phase One Configurations"
@echo " generate-phase-two-configs - Generate Phase Two Configurations"
@echo " generate-phase-three-configs - Generate Phase Three Configurations"
@echo ""
@echo "General Usage:"
@echo " make help - Show this help message"
@echo " make <command> - Run a specific command"
@echo ""
@echo "==============================================================="

stageDev:
PROFILE=stageDev docker compose --profile stageDev up --attach conductor
# ================================================================================== #
# Conductor: #
# ================================================================================== #

arrangerDev:
PROFILE=arrangerDev docker compose --profile arrangerDev up --attach conductor
# Run pre-deployment checks
phase0:
@echo "Running Pre-deployment checks..."
chmod +x ./apps/conductor/scripts/deployments/phase0.sh
./apps/conductor/scripts/deployments/phase0.sh

maestroDev:
PROFILE=maestroDev docker compose --profile maestroDev up --attach conductor
# Start Phase One development environment
phase1:
@echo "Starting Phase 1 development environment..."
PROFILE=phase1 docker compose -f ./docker-compose.yml --profile phase1 up --attach conductor

songDev:
PROFILE=songDev docker compose --profile songDev up --attach conductor
# Start Phase Two development environment
phase2:
@echo "Starting Phase 2 development environment..."
PROFILE=phase2 docker compose -f ./docker-compose.yml --profile phase2 up --attach conductor

scoreDev:
PROFILE=scoreDev docker compose --profile scoreDev up --attach conductor
# Start Phase Three development environment
phase3:
@echo "Starting Phase 3 development environment..."
PROFILE=phase3 docker compose -f ./docker-compose.yml --profile phase3 up --attach conductor

# Start Stage development environment
stage-dev:
@echo "Starting Stage development environment..."
PROFILE=stageDev docker compose -f ./docker-compose.yml --profile stageDev up --attach conductor


# Deploy the stage application (with pre-checks)
deploy-stage: pre-check
@echo "Deploying stage application..."
docker build -t stageimage:1.0 .

# Gracefully shutdown all containers while preserving volumes
down:
PROFILE=platform docker compose --profile platform down
@echo "Shutting down all running containers..."
PROFILE=default docker compose -f ./docker-compose.yml --profile default down

# Shutdown all containers and remove all volumes (WARNING: Deletes all data)
reset:
@echo "\033[1;33mWarning:\033[0m This will remove all containers AND their volumes. Data will be lost."
@read -p "Are you sure you want to continue? [y/N] " confirm; \
if [ "$$confirm" = "y" ] || [ "$$confirm" = "Y" ]; then \
PROFILE=default docker compose -f ./docker-compose.yml --profile default down -v ; \
else \
echo "Operation cancelled"; \
fi

# Remove all documents from Elasticsearch (preserves index structure)
clean-data:
@echo "\033[1;33mWarning:\033[0m This will delete ALL data from the Elasticsearch index."
@read -p "Are you sure you want to continue? [y/N] " confirm; \
if [ "$$confirm" = "y" ] || [ "$$confirm" = "Y" ]; then \
PROFILE=clean docker compose -f ./docker-compose.yml --profile clean up --attach conductor; \
else \
echo "\033[1;36mOperation cancelled\033[0m"; \
fi

# ================================================================================== #
# Composer: #
# ================================================================================== #

# Generate Phase One Configurations
generate-phase-one-configs:
@echo "Generating Phase One Configurations..."
PROFILE=generatePhaseOneConfigs docker compose -f ./docker-composer.yml --profile generatePhaseOneConfigs up --attach composer

# Generate Phase Two Configurations
generate-phase-two-configs:
@echo "Generating Phase Two Configurations..."
PROFILE=generatePhaseTwoConfigs docker compose -f ./docker-composer.yml --profile generatePhaseTwoConfigs up --attach composer

# Generate Phase Three Configurations
generate-phase-three-configs:
@echo "Generating Phase Three Configurations..."
PROFILE=generatePhaseThreeConfigs docker compose -f ./docker-composer.yml --profile generatePhaseThreeConfigs up --attach composer
171 changes: 122 additions & 49 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,69 +1,142 @@
# Conductor
# Overture Documentation Portal

Conductor is a flexible Docker Compose setup that simplifies the process of spinning up Overture development and deployment configurations using Docker profiles and extensible scripting events.
A comprehensive documentation portal for the Overture data platform implementation, built with Next.js and featuring a responsive, mobile-friendly design with intuitive navigation.

## Key Features
## Overview

- **Profile-based Deployments**: Uses Docker profiles to manage different environment setups.
- **Conductor-driven Execution**: The Conductor service executes ordered scripts based on the `PROFILE` environment variable.
This documentation portal provides a structured, user-friendly interface for accessing Overture's Prelude documentation. It features:

- Responsive sidebar navigation with mobile support
- Markdown content rendering with automatic table of contents
- Section-based navigation with previous/next links
- Copy-to-clipboard functionality for headings
- Dynamic content loading

## Getting Started

**1. Clone the repo's `main` branch**
### Prerequisites

```
git clone -b concerto https://github.com/overture-stack/composer.git && cd composer
- **Docker Desktop 4.39.0+** with:
- 8-core CPU minimum
- 8 GB memory
- 2 GB swap
- 64 GB virtual disk
- **Node.js 18+ and npm 9+**

### First Steps

Start by running the pre-deployment check to ensure your environment is properly configured:

```bash
make phase0
```

**2. Run one of the following commands to spin up different environments:**
This command will verify your system meets all requirements and provide guidance on any necessary adjustments.

| Environment | Unix/macOS | Windows |
|-------------|------------|---------|
| Overture Platform | `make platform` | `make.bat platform` |
| Stage Dev | `make stageDev` | `make.bat stageDev` |
| Arranger Dev | `make arrangerDev` | `make.bat arrangerDev` |
| Maestro Dev | `make maestroDev` | `make.bat maestroDev` |
| Song Dev | `make songDev` | `make.bat songDev` |
| Score Dev | `make scoreDev` | `make.bat scoreDev` |
### Deployment Options

Each command spins up complementary services for the specified development environment.
The portal can be deployed in phases, with each phase adding additional functionality:

## Repository Structure
```bash
# Deploy Phase 1: Data Exploration & Theming
make phase1

# Deploy Phase 2: Tabular Data Management
make phase2

# Deploy Phase 3: File Management
make phase3

# Run Stage in development mode
make stage-dev

# Reset all containers and volumes
make reset
```
.
β”œβ”€β”€ conductorScripts/
β”‚ β”œβ”€β”€ deployments
β”‚ └── services
β”œβ”€β”€ configurationFiles/
β”‚ β”œβ”€β”€ arrangerConfigs
β”‚ β”œβ”€β”€ elasticsearchConfigs
β”‚ └── keycloakConfigs
β”œβ”€β”€ guideMaterials
β”œβ”€β”€ persistentStorage/
β”‚ β”œβ”€β”€ data-keycloak-db
β”‚ β”œβ”€β”€ data-minio
β”‚ └── data-song-db
β”œβ”€β”€ Makefile
└── make.bat
```

- **`conductorScripts/`** Contains scripts for orchestrating the deployment process.
- `deployments/`: Scripts that execute service scripts sequentially based on the deployment configuration. These also include custom post-deployment logs with essential next steps for the deployment scenario.
- `services/`: Modular scripts for individual service setup tasks. Each file is named according to its purpose, with inline comments documenting the code.
### Accessing the Portal

Once running, access the documentation portal at: [http://localhost:3000](http://localhost:3000)

## Documentation Structure

- **`configurationFiles/`** Stores all required configuration files, including:
- `arrangerConfigs/`: Configuration files specific to Arranger.
- `elasticsearchConfigs/`: Configuration files for Elasticsearch, encompassing indexing mappings and documents for seeding data.
- `keycloakConfigs/`: Configuration files for Keycloak, including preconfigured realm files and Overture API key provider details.
The documentation is organized into phases matching the Prelude development workflow:

- **`guideMaterials/`** Supplementary folders and files for use with the [Overture guides](https://www.overture.bio/documentation/guides/).
- **Introduction**: Overview of the Prelude toolkit and its components
- **Phase One**: Data Exploration & Theming (Elasticsearch, Arranger, Stage)
- **Phase Two**: Tabular Data Management (Lyric, Lectern, Postgres, MongoDB)
- **Phase Three**: File Management (Song, Score, Object Storage)
- **Phase Four**: Identity & Access (Coming in future release)
- **Support**: How to get help and contribute

- **`persistentStorage/`** Directory for storing persistent data during container startups and restarts. These folders come pre-loaded with mock data.
- `data-keycloak-db/`: Persistent local storage for the Keycloak database.
- `data-minio/`: Persistent local storage for MinIO object storage.
- `data-song-db/`: Persistent local storage for the Song database.
## Development

### Local Development Environment

To modify the documentation portal itself:

1. Clone the repository
2. Install dependencies:
```bash
cd apps/stage
npm install
```
3. Run the development server:
```bash
npm run dev
```

### Updating Documentation Content

Documentation content is stored as Markdown files in the `public/docs` directory. To add or update content:

1. Files are prefixed with numbers (`00-`, `01-`, etc.) to control ordering
2. Each file should start with a top-level heading (`# Title`)
3. Place images in `public/docs/images/`
4. Use standard Markdown syntax for formatting

## Project Structure

The project follows a modular structure with two main applications: Conductor (for data management) and Stage (for the front-end portal).

```
β”œβ”€β”€ apps/
β”‚ β”œβ”€β”€ composer/ # Config generation tool
β”‚ β”‚ └── src/ # Source code
β”‚ β”‚ β”œβ”€β”€ cli/ # CLI interface
β”‚ β”‚ β”œβ”€β”€ commands/ # Command implementations
β”‚ β”‚ β”œβ”€β”€ services/ # Core functions for config generation
β”‚ β”‚ └── utils/ # Utility functions
β”‚ β”‚
β”‚ β”œβ”€β”€ conductor/ # Data management tool
β”‚ β”‚ β”œβ”€β”€ src/ # Source code
β”‚ β”‚ β”‚ β”œβ”€β”€ cli/ # CLI interface
β”‚ β”‚ β”‚ β”œβ”€β”€ commands/ # Command implementations
β”‚ β”‚ β”‚ β”œβ”€β”€ services/ # Core services (ES, Lectern, etc.)
β”‚ β”‚ β”‚ └── utils/ # Utility functions
β”‚ β”‚ β”œβ”€β”€ configs/ # Configuration files
β”‚ β”‚ β”‚ β”œβ”€β”€ arrangerConfigs/ # Arranger UI configurations
β”‚ β”‚ β”‚ β”œβ”€β”€ elasticsearchConfigs/ # Elasticsearch mappings
β”‚ β”‚ β”‚ β”œβ”€β”€ lecternDictionaries/ # Data dictionaries
β”‚ β”‚ β”‚ └── songSchemas/ # Song schemas
β”‚ β”‚ └── scripts/ # Deployment and service scripts
β”‚ β”‚ β”œβ”€β”€ deployments/ # Phase deployment scripts
β”‚ β”‚ └── services/ # Service management scripts
β”‚ β”‚
β”‚ └── stage/ # Frontend portal
β”‚ β”œβ”€β”€ components/
β”‚ β”‚ β”œβ”€β”€ pages/ # Page-specific components
β”‚ β”‚ └── theme/ # Theming
β”‚ β”œβ”€β”€ pages/ # Next.js pages
β”‚ └── public/ # Static assets
β”‚ └── docs/ # Markdown documentation files
β”‚ └── images/ # Documentation images
β”‚
β”œβ”€β”€ configs/ # Symlink to conductor configs
β”œβ”€β”€ data/ # Data files
└── docs/ # Symlink to Stage docs
```

- **`Makefile`** Contains [`make` commands](https://www.gnu.org/software/make/manual/make.html#Overview-of-make) for Unix-based systems (macOS, Linux) to streamline Docker operations.
## Support

- **`make.bat`** Windows equivalent of the Makefile, featuring batch commands tailored for Windows systems.
For assistance, reach out via the [community support channels](https://docs.overture.bio/community/support), for private inquiries email us at [[email protected]](mailto:[email protected]).
Loading