debian-mirror-gitlab/app/assets/javascripts/clusters/services/clusters_service.js
2021-09-30 23:02:18 +05:30

19 lines
411 B
JavaScript

import axios from '../../lib/utils/axios_utils';
export default class ClusterService {
constructor(options = {}) {
this.options = options;
}
fetchClusterStatus() {
return axios.get(this.options.endpoint);
}
fetchClusterEnvironments() {
return axios.get(this.options.clusterEnvironmentsEndpoint);
}
static updateCluster(endpoint, data) {
return axios.put(endpoint, data);
}
}