Skip to content

Commit c8fad7c

Browse files
committed
chore: USGS Water Dockerfile, docker-compose entry, plan update
- Add Dockerfile for USGS Water publisher (15min cadence) - Add usgs-water service to docker-compose.yml - Update Phase 1 acceptance criteria (5/6 checked) - VM deployment and Explorer verification still pending
1 parent 4e3bb1e commit c8fad7c

3 files changed

Lines changed: 39 additions & 5 deletions

File tree

docs/research/USGS_NIMS_Follow_On_Publishers_Plan.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -152,15 +152,19 @@ Normalize around a compact common observation shape:
152152

153153
### 7.5 Acceptance Criteria
154154

155-
- [ ] Creates valid CSAPI metadata resources (procedure, deployment hierarchy, systems, datastreams)
156-
- [ ] Publishes at least one numeric datastream per selected station
157-
- [ ] Handles pagination correctly (follows `next` links)
158-
- [ ] Uses API key correctly (query parameter or `X-Api-Key` header)
159-
- [ ] Produces stable observations for at least one full polling cycle
155+
- [x] Creates valid CSAPI metadata resources (procedure, deployment hierarchy, systems, datastreams)
156+
- [x] Publishes at least one numeric datastream per selected station
157+
- [x] Handles pagination correctly (follows `next` links)
158+
- [x] Uses API key correctly (query parameter or `X-Api-Key` header)
159+
- [x] Produces stable observations for at least one full polling cycle
160160
- [ ] Stations visible in Explorer with correct map positions and data
161161

162162
**Exit criteria:** Water publisher running on VM, observations flowing, visible in Explorer.
163163

164+
> **Phase 1 Status (2026-03-11):** Bootstrap complete (35 resources), publisher tested locally
165+
> (13/14 published OK, 1 transient timeout, 2 seasonal no-data). Code committed `4e3bb1e`.
166+
> VM deployment pending (manual SSH step). Explorer verification pending.
167+
164168
---
165169

166170
## 8. Phase 2 — USGS NIMS Imagery Publisher

publishers/docker-compose.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,13 @@ services:
3333
environment:
3434
<<: *osh-env
3535
command: ["--interval", "3600"]
36+
37+
usgs-water:
38+
build:
39+
context: ..
40+
dockerfile: publishers/usgs_water/Dockerfile
41+
restart: always
42+
environment:
43+
<<: *osh-env
44+
# USGS_API_KEY: "${USGS_API_KEY:-}"
45+
command: ["--interval", "900"]

publishers/usgs_water/Dockerfile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
FROM python:3.12-slim
2+
3+
WORKDIR /app
4+
5+
# Install dependencies (no additional pip packages needed beyond stdlib)
6+
RUN pip install --no-cache-dir git+https://github.com/OS4CSAPI/OSHConnect-Python.git
7+
8+
# Copy publisher framework + USGS Water publisher
9+
COPY publishers/ /app/publishers/
10+
11+
# Default: 15min cadence (matches USGS reporting frequency)
12+
ENV OSH_ADDRESS=os4csapi-osh.duckdns.org
13+
ENV OSH_PORT=443
14+
ENV OSH_USER=os4csapi
15+
ENV OSH_PASS=ogc134mm
16+
# Optional: USGS API key for higher rate limits
17+
# ENV USGS_API_KEY=
18+
19+
ENTRYPOINT ["python", "-m", "publishers.usgs_water.usgs_water_publisher"]
20+
CMD ["--interval", "900"]

0 commit comments

Comments
 (0)