chore: consolidate documentation — delete status/fix/progress cruft
Before: 335 tracked .md files; top level had 14 README-like docs; docs/ contained ~234 files, most of them auto/LLM-generated status reports (ALL_*_COMPLETE*, *_FIX*, DEPLOYMENT_*_FINAL*, etc.). After: 132 tracked .md files. Repo now has exactly five top-level docs: README.md, QUICKSTART.md, RUNBOOK.md, CONTRIBUTING.md, CHANGELOG.md (moved up from docs/). Keeper philosophy in docs/: - API, CCIP (ops + security + receiver/router refs), Chainlist refs, compliance, deployment (guides not status), database connection, legal compliance, metamask integration, production checklist, tiered-architecture implementation/setup, reusable-components plan, token-mechanism doc, wrap-and-bridge operational reference, plus docs/specs/** and docs/api/ / docs/openapi/ trees. Deleted (git history preserves provenance): - All 'ALL_*_COMPLETE*' / '*_FIX*' / '*_FIXED*' / '*_FINAL*' / '*_STATUS*' / '*_PROGRESS*' / '*_SUMMARY*' files. - BLOCKSCOUT_*_FIX / _CRASH / _INITIALIZATION / _SCHEMA / _YAML / _SKIP / _NEXT_STEPS / _START_AND_BUILD / _DATABASE_CREDENTIALS (the last contained passwords). - CCIP_IMPLEMENTATION_* / CCIP_CURRENT_STATUS / CCIP_GAP_* (gap analyses are not a sustained reference). - NPMPLUS_CREDENTIALS_GUIDE.md (contained creds). - LETSENCRYPT_CONFIGURATION_GUIDE.md (contained creds; will be re-introduced as runbook content post-secrets-scrub). - docs/diagnostic-reports/, docs/feature-flags/ (run-time artifacts). README.md: dead links (START_HERE, README_DEPLOYMENT, COMPLETE_DEPLOYMENT, DEPLOYMENT_COMPLETE_FINAL) replaced with links to the five canonical top-level docs + docs/ index.
This commit is contained in:
@@ -1,91 +0,0 @@
|
||||
# Corrected Blockscout Fix Commands
|
||||
|
||||
## Issues Found
|
||||
1. Container is not running, so can't use `--network container:$BLOCKSCOUT_CONTAINER`
|
||||
2. System uses `docker-compose` (with hyphen) not `docker compose`
|
||||
3. Need to use postgres container's network instead
|
||||
|
||||
## Corrected Commands (Run in VMID 5000)
|
||||
|
||||
### Step 1: Run Migrations Using Postgres Network
|
||||
|
||||
```bash
|
||||
# Get postgres container network
|
||||
POSTGRES_NETWORK=$(docker inspect blockscout-postgres | grep -A 20 "Networks" | grep -oP '"NetworkID": "\K[^"]+' | head -1)
|
||||
|
||||
# Or use the network name directly
|
||||
NETWORK_NAME=$(docker inspect blockscout-postgres -f '{{range $key, $value := .NetworkSettings.Networks}}{{$key}}{{end}}')
|
||||
|
||||
# Run migrations using postgres network
|
||||
docker run --rm \
|
||||
--network $NETWORK_NAME \
|
||||
-e DATABASE_URL=postgresql://blockscout:blockscout@blockscout-postgres:5432/blockscout \
|
||||
blockscout/blockscout:latest \
|
||||
bin/blockscout eval "Explorer.Release.migrate()"
|
||||
```
|
||||
|
||||
### Step 2: Alternative - Use Docker Network Bridge
|
||||
|
||||
```bash
|
||||
# Find the bridge network
|
||||
BRIDGE_NETWORK=$(docker network ls | grep bridge | awk '{print $1}' | head -1)
|
||||
|
||||
# Run migrations
|
||||
docker run --rm \
|
||||
--network $BRIDGE_NETWORK \
|
||||
--add-host=postgres:$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' blockscout-postgres) \
|
||||
-e DATABASE_URL=postgresql://blockscout:blockscout@postgres:5432/blockscout \
|
||||
blockscout/blockscout:latest \
|
||||
bin/blockscout eval "Explorer.Release.migrate()"
|
||||
```
|
||||
|
||||
### Step 3: Simplest - Use Host Network
|
||||
|
||||
```bash
|
||||
# Use host network and connect to localhost
|
||||
docker run --rm \
|
||||
--network host \
|
||||
-e DATABASE_URL=postgresql://blockscout:blockscout@localhost:5432/blockscout \
|
||||
blockscout/blockscout:latest \
|
||||
bin/blockscout eval "Explorer.Release.migrate()"
|
||||
```
|
||||
|
||||
### Step 4: Update docker-compose.yml (Use docker-compose with hyphen)
|
||||
|
||||
```bash
|
||||
cd /opt/blockscout # or wherever docker-compose.yml is
|
||||
|
||||
# Backup
|
||||
cp docker-compose.yml docker-compose.yml.backup
|
||||
|
||||
# Update command - check current command first
|
||||
grep -A 2 "command:" docker-compose.yml
|
||||
|
||||
# Update to run migrations before start
|
||||
sed -i 's|command:.*blockscout start|command: sh -c "bin/blockscout eval '\''Explorer.Release.migrate()'\'' \&\& bin/blockscout start"|' docker-compose.yml
|
||||
sed -i 's|command:.*/app/bin/blockscout start|command: sh -c "bin/blockscout eval '\''Explorer.Release.migrate()'\'' \&\& bin/blockscout start"|' docker-compose.yml
|
||||
```
|
||||
|
||||
### Step 5: Restart Using docker-compose (with hyphen)
|
||||
|
||||
```bash
|
||||
cd /opt/blockscout
|
||||
docker-compose down blockscout
|
||||
docker-compose up -d blockscout
|
||||
|
||||
# Wait and check
|
||||
sleep 30
|
||||
docker ps | grep blockscout
|
||||
docker logs blockscout 2>&1 | tail -20
|
||||
```
|
||||
|
||||
## Complete One-Line Fix
|
||||
|
||||
```bash
|
||||
# Run migrations using host network
|
||||
docker run --rm --network host -e DATABASE_URL=postgresql://blockscout:blockscout@localhost:5432/blockscout blockscout/blockscout:latest bin/blockscout eval "Explorer.Release.migrate()" && \
|
||||
cd /opt/blockscout && \
|
||||
sed -i 's|command:.*blockscout start|command: sh -c "bin/blockscout eval '\''Explorer.Release.migrate()'\'' \&\& bin/blockscout start"|' docker-compose.yml && \
|
||||
docker-compose restart blockscout
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user