Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Docker Publishing
on:
push:
branches:
- '*'
- "*"
tags:
- '[0-9]+.[0-9]+.[0-9]+'
- "[0-9]+.[0-9]+.[0-9]+"

jobs:
publish-images:
Expand All @@ -25,8 +25,8 @@ jobs:
file: docker/app/Dockerfile
push: true
tags: |
pcic/vhmo-app:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/vhmo-app:latest' || '' }}
pcic/chyp-app:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/chyp-app:latest' || '' }}

- name: Build and Publish Data Import
uses: docker/build-push-action@v4
Expand All @@ -35,8 +35,8 @@ jobs:
file: docker/data-import/Dockerfile
push: true
tags: |
pcic/vhmo-data-import:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/vhmo-data-import:latest' || '' }}
pcic/chyp-data-import:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/chyp-data-import:latest' || '' }}

- name: Build and Publish PostGIS
uses: docker/build-push-action@v4
Expand All @@ -45,15 +45,15 @@ jobs:
file: docker/PostGIS/Dockerfile
push: true
tags: |
pcic/vhmo-postgis:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/vhmo-postgis:latest' || '' }}
pcic/chyp-postgis:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/chyp-postgis:latest' || '' }}

- name: Build and Publish BBOX server
uses: docker/build-push-action@v4
with:
context: .
file: docker/BBOX/Dockerfile
push: true
tags: |
pcic/vhmo-server:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/vhmo-server:latest' || '' }}
pcic/chyp-server:${{ github.ref_name }}
${{ github.ref_name == 'main' && 'pcic/chyp-server:latest' || '' }}
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Vector Hydrologic Model Output Portal (VHMO) — BCSRIF-P2
# Channel-Scale Hydrologic Model Output Portal (CHYP) — BCSRIF-P2

This project provides an interactive web portal for visualizing and downloading hydrological model data, including water temperature, streamflow, and oxygen concentration timeseries.

Expand Down Expand Up @@ -101,10 +101,10 @@ BC Geographic Warehouse (BCGW) [Public Map Server](https://delivery.maps.gov.bc.

The following images are published to Docker Hub:

- `pcic/vhmo-app`: Frontend application
- `pcic/vhmo-data-import`: Data import utilities
- `pcic/vhmo-postgis`: PostGIS database
- `pcic/vhmo-server`: BBOX tile server
- `pcic/chyp-app`: Frontend application
- `pcic/chyp-data-import`: Data import utilities
- `pcic/chyp-postgis`: PostGIS database
- `pcic/chyp-server`: BBOX tile server

## Requirements

Expand Down
2 changes: 1 addition & 1 deletion app/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
<link rel="preload" as="image" href="https://swarm.pacificclimate.org/tiles/bc-albers-lite/6/33/29.png" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vector Hydrologic Model Output</title>
<title>Channel-Scale Hydrologic Model Output Portal</title>
</head>

<body>
Expand Down
4 changes: 2 additions & 2 deletions app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
"build": "vite build",
"lint": "eslint .",
"preview": "vite preview",
"docker-build": "docker build --file ../docker/app/Dockerfile --tag vec-hydro-portal ../",
"docker-run": "docker run --rm -p 3001:8080 vec-hydro-portal"
"docker-build": "docker build --file ../docker/app/Dockerfile --tag chyp ../",
"docker-run": "docker run --rm -p 3001:8080 chyp"
},
"dependencies": {
"leaflet": "^1.9.4",
Expand Down
2 changes: 1 addition & 1 deletion app/src/components/map/FwaNameSearch.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ const fetchLakeMeta = (keys, signal) =>
);

const loadIndex = async () => {
const resp = await fetch(`/vec-hydro-portal/fwa_index.json`);
const resp = await fetch(`/chyp/fwa_index.json`);
if (!resp.ok) throw new Error("Index load failed");
return resp.json();
};
Expand Down
2 changes: 1 addition & 1 deletion app/src/components/map/MapComponent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ const MapComponent = () => {
zoomAnimationThreshold={4}
markerZoomAnimation={true}
>
<LogoBox projectName="Vector Hydrologic Model Output" />
<LogoBox projectName="Channel-Scale Hydrologic Model Output Portal" />
<Suspense fallback={null}>
<HelpGuide />
</Suspense>
Expand Down
10 changes: 1 addition & 9 deletions app/src/services/timeseriesApi.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,11 @@ export const downloadTimeseries = async (outletId, selections) => {

if (!timeseriesId) throw new Error("No matching timeseries found");

const response = await fetch(
`${BASE_URL}/outlets/${outletId}/timeseries/${timeseriesId}/data`
);
if (!response.ok) throw new Error("Failed to fetch data");

const data = await response.text();
const blob = new Blob([data], { type: "text/csv" });
const url = window.URL.createObjectURL(blob);
const url = `${BASE_URL}/outlets/${outletId}/timeseries/${timeseriesId}/data`;
const a = document.createElement("a");
a.href = url;
a.download = `${outletId}_${selections.model}_${selections.scenario}_${apiVariable}.csv`;
document.body.appendChild(a);
a.click();
document.body.removeChild(a);
window.URL.revokeObjectURL(url);
};
2 changes: 1 addition & 1 deletion app/vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export default defineConfig({
"https://swarm.pacificclimate.org/tiles/bc-albers-lite/{z}/{x}/{y}.png",
}),
],
base: "/vec-hydro-portal",
base: "/chyp",
// Local Dev only
server: {
warmup: {
Expand Down
2 changes: 1 addition & 1 deletion docker/app/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const path = require("node:path");

const PORT = Number(process.env.PORT || 8080);
const DIST_DIR = path.join(__dirname, "dist");
const BASE_PATH = "/vec-hydro-portal";
const BASE_PATH = "/chyp";

const MIME_TYPES = {
".css": "text/css; charset=utf-8",
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading