Skip to content

Commit 2ff5564

Browse files
kltmclaude
andcommitted
Add CLAUDE.md with project context and deployment references (#35)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 791a50b commit 2ff5564

1 file changed

Lines changed: 57 additions & 0 deletions

File tree

CLAUDE.md

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# CLAUDE.md
2+
3+
## Project overview
4+
5+
go-graphstore is the Gene Ontology's Blazegraph SPARQL endpoint service. It packages Blazegraph into a Docker container behind an Apache reverse proxy and deploys it to AWS EC2 instances using Terraform and Ansible.
6+
7+
The service runs at `rdf.geneontology.org` (production) and `rdf-internal.berkeleybop.io` (internal).
8+
9+
## Repository structure
10+
11+
- `docker/Dockerfile` — Multi-stage build: Maven/OpenJDK 8 builder, openjdk:8-jre runtime. Exposes port 8899.
12+
- `conf/` — Blazegraph configuration (readonly_cors.xml for CORS and query timeouts).
13+
- `provision/` — All deployment infrastructure:
14+
- `aws/main.tf` — Terraform config, uses module from `geneontology/devops-aws-go-instance` (ref V3.1).
15+
- `build_images.yaml`, `stage.yaml`, `start_services.yaml`, `down_services.yaml` — Ansible playbooks.
16+
- `vars.yaml`, `ssl-vars.yaml`, `qos-vars.yaml` — Ansible variables.
17+
- `templates/` — Jinja2 templates for docker-compose, Apache vhosts, QoS, Blazegraph config.
18+
- `production/` — Production config samples. See [canonical deployment docs](https://github.com/geneontology/devops-documentation/blob/main/README.graphstore.md) for production procedures; general devops setup (credentials, environment) is at [README.setup.md](https://github.com/geneontology/devops-documentation/blob/main/README.setup.md).
19+
- `pom.xml` — Maven project: blazegraph-jar 2.1.4, jetty-servlets 9.2.3.
20+
- `Makefile` — Local build and Blazegraph loading targets.
21+
- `.github/workflows/aws_test.yaml` — CI/CD: provisions a test instance on push to master.
22+
23+
## Deployment
24+
25+
Canonical deployment documentation lives at:
26+
https://github.com/geneontology/devops-documentation/blob/main/README.graphstore.md
27+
28+
Key points:
29+
- `go-deploy` is the high-level deployment tool for day-to-day operations. Use it for provisioning, deploying stacks, inspecting state, and destroying instances.
30+
- Raw `terraform` commands are for lower-level debugging only.
31+
- Two deployment tracks: **production** (geneontology.org) and **internal** (berkeleybop.io).
32+
- Workspace naming convention: `production-YYYY-MM-DD` or `internal-YYYY-MM-DD`.
33+
- Config files use `REPLACE_ME` placeholders. Always scan for remaining placeholders before deploying: `grep -rn 'REPLACE_ME\|YYYY-MM-DD' config-stack.yaml config-instance.yaml ssl-vars.yaml vars.yaml aws/backend.tf`
34+
35+
## Related repositories
36+
37+
- [devops-documentation](https://github.com/geneontology/devops-documentation) — Canonical deployment docs (README.graphstore.md). Checked out at `../devops-documentation`.
38+
- [devops-aws-go-instance](https://github.com/geneontology/devops-aws-go-instance) — Terraform module for AWS EC2 provisioning (consumed via `main.tf`).
39+
- [devops-apache-proxy](https://github.com/geneontology/devops-apache-proxy) — Apache reverse proxy Docker image (consumed at deploy time).
40+
- [devops-deployment-scripts](https://github.com/geneontology/devops-deployment-scripts) — Builds the `geneontology/go-devops-base` Docker image used as the devops environment.
41+
42+
## Build and test
43+
44+
Local build (requires Maven, Java 8):
45+
```
46+
make all
47+
make load-blazegraph
48+
```
49+
50+
CI runs on push to master via `.github/workflows/aws_test.yaml` — provisions a test instance, verifies the service responds, then destroys it.
51+
52+
## Important conventions
53+
54+
- The default instance user is `ubuntu`.
55+
- Docker container name for devops work: `go-graphstore`.
56+
- Credentials and SSH keys go in `/tmp/` inside the devops container (see README.setup.md).
57+
- Never commit credentials, SSH keys, or `backend.tf` files (covered by `.gitignore`).

0 commit comments

Comments
 (0)