Skip to content

Commit

Permalink
Merge pull request #7 from huntdatacenter/price-calc-hans
Browse files Browse the repository at this point in the history
Price calculator / estimator
  • Loading branch information
matuskosut authored Dec 3, 2024
2 parents 05a41fc + fede0d0 commit 45167f3
Show file tree
Hide file tree
Showing 12 changed files with 3,273 additions and 773 deletions.
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@
"@fortawesome/fontawesome-svg-core": "^6.6.0",
"@fortawesome/free-solid-svg-icons": "^6.6.0",
"@fortawesome/vue-fontawesome": "^3.0.8",
"@mdi/font": "^7.4.47"
"@mdi/font": "^7.4.47",
"axios": "^1.6.8",
"buffer": "^6.0.3"
}
}
33 changes: 33 additions & 0 deletions pages/.vitepress/api/csv.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import data from './data.json';
import axios from "axios";

export default {
async getComputeFlavors() {
try {
const res = await axios.get("https://assets.hdc.ntnu.no/assets/prices/v4/hunt-cloud-price-list-4-2.json")
return res.data
} catch (error) {
console.error("Error fetching compute flavors:", error);
return [];
}

},
async getAvailableGPUS() {
try {
const res = await axios.get("https://assets.hdc.ntnu.no/assets/js/gpus.json")
return res.data
} catch (error) {
console.error("Error fetching compute flavors:", error);
return [];
}
},
async getMachines() {
try {
const response = await axios.get("https://assets.hdc.ntnu.no/assets/js/flavors.json");
return response.data;
} catch (error) {
console.error("Error fetching machines:", error);
return [];
}
}
};
Loading

0 comments on commit 45167f3

Please sign in to comment.