|
@@ -1,35 +1,35 @@
|
|
|
import React, { Component } from "react";
|
|
import React, { Component } from "react";
|
|
|
|
|
+import { RouteComponentProps, withRouter } from "react-router";
|
|
|
import posthog from "posthog-js";
|
|
import posthog from "posthog-js";
|
|
|
import styled from "styled-components";
|
|
import styled from "styled-components";
|
|
|
|
|
+import * as FullStory from "@fullstory/browser";
|
|
|
|
|
|
|
|
-import { Context } from "shared/Context";
|
|
|
|
|
import api from "shared/api";
|
|
import api from "shared/api";
|
|
|
|
|
+import { Context } from "shared/Context";
|
|
|
|
|
+import { PorterUrl } from "shared/routing";
|
|
|
import { ClusterType, ProjectType } from "shared/types";
|
|
import { ClusterType, ProjectType } from "shared/types";
|
|
|
|
|
|
|
|
-import Sidebar from "./sidebar/Sidebar";
|
|
|
|
|
-import Dashboard from "./dashboard/Dashboard";
|
|
|
|
|
-import ClusterDashboard from "./cluster-dashboard/ClusterDashboard";
|
|
|
|
|
|
|
+import ConfirmOverlay from "components/ConfirmOverlay";
|
|
|
import Loading from "components/Loading";
|
|
import Loading from "components/Loading";
|
|
|
-import Templates from "./templates/Templates";
|
|
|
|
|
|
|
+import ClusterDashboard from "./cluster-dashboard/ClusterDashboard";
|
|
|
|
|
+import Dashboard from "./dashboard/Dashboard";
|
|
|
import Integrations from "./integrations/Integrations";
|
|
import Integrations from "./integrations/Integrations";
|
|
|
-import UpdateClusterModal from "./modals/UpdateClusterModal";
|
|
|
|
|
|
|
+import Templates from "./launch/Launch";
|
|
|
import ClusterInstructionsModal from "./modals/ClusterInstructionsModal";
|
|
import ClusterInstructionsModal from "./modals/ClusterInstructionsModal";
|
|
|
-import IntegrationsModal from "./modals/IntegrationsModal";
|
|
|
|
|
import IntegrationsInstructionsModal from "./modals/IntegrationsInstructionsModal";
|
|
import IntegrationsInstructionsModal from "./modals/IntegrationsInstructionsModal";
|
|
|
-import NewProject from "./new-project/NewProject";
|
|
|
|
|
|
|
+import IntegrationsModal from "./modals/IntegrationsModal";
|
|
|
|
|
+import Modal from "./modals/Modal";
|
|
|
|
|
+import UpdateClusterModal from "./modals/UpdateClusterModal";
|
|
|
import Navbar from "./navbar/Navbar";
|
|
import Navbar from "./navbar/Navbar";
|
|
|
|
|
+import NewProject from "./new-project/NewProject";
|
|
|
import ProjectSettings from "./project-settings/ProjectSettings";
|
|
import ProjectSettings from "./project-settings/ProjectSettings";
|
|
|
-import ConfirmOverlay from "components/ConfirmOverlay";
|
|
|
|
|
-import Modal from "./modals/Modal";
|
|
|
|
|
-import * as FullStory from "@fullstory/browser";
|
|
|
|
|
-import { Redirect, RouteComponentProps, withRouter } from "react-router";
|
|
|
|
|
-import { PorterUrls } from "shared/routing";
|
|
|
|
|
|
|
+import Sidebar from "./sidebar/Sidebar";
|
|
|
|
|
|
|
|
type PropsType = RouteComponentProps & {
|
|
type PropsType = RouteComponentProps & {
|
|
|
logOut: () => void;
|
|
logOut: () => void;
|
|
|
currentProject: ProjectType;
|
|
currentProject: ProjectType;
|
|
|
currentCluster: ClusterType;
|
|
currentCluster: ClusterType;
|
|
|
- currentRoute: PorterUrls;
|
|
|
|
|
|
|
+ currentRoute: PorterUrl;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
type StateType = {
|
|
type StateType = {
|
|
@@ -128,18 +128,18 @@ class Home extends Component<PropsType, StateType> {
|
|
|
provisionDOCR = (integrationId: number, tier: string, callback?: any) => {
|
|
provisionDOCR = (integrationId: number, tier: string, callback?: any) => {
|
|
|
console.log("Provisioning DOCR...");
|
|
console.log("Provisioning DOCR...");
|
|
|
return api
|
|
return api
|
|
|
- .createDOCR(
|
|
|
|
|
- "<token>",
|
|
|
|
|
- {
|
|
|
|
|
- do_integration_id: integrationId,
|
|
|
|
|
- docr_name: this.props.currentProject.name,
|
|
|
|
|
- docr_subscription_tier: tier,
|
|
|
|
|
- },
|
|
|
|
|
- {
|
|
|
|
|
- project_id: this.props.currentProject.id,
|
|
|
|
|
- }
|
|
|
|
|
- )
|
|
|
|
|
- .then(() => callback());
|
|
|
|
|
|
|
+ .createDOCR(
|
|
|
|
|
+ "<token>",
|
|
|
|
|
+ {
|
|
|
|
|
+ do_integration_id: integrationId,
|
|
|
|
|
+ docr_name: this.props.currentProject.name,
|
|
|
|
|
+ docr_subscription_tier: tier,
|
|
|
|
|
+ },
|
|
|
|
|
+ {
|
|
|
|
|
+ project_id: this.props.currentProject.id,
|
|
|
|
|
+ }
|
|
|
|
|
+ )
|
|
|
|
|
+ .then(() => callback());
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
provisionDOKS = (integrationId: number, region: string) => {
|
|
provisionDOKS = (integrationId: number, region: string) => {
|