diff --git a/Dashboard/src/Components/Header/Header.tsx b/Dashboard/src/Components/Header/Header.tsx index 27255b00e0..2ebc9c378a 100644 --- a/Dashboard/src/Components/Header/Header.tsx +++ b/Dashboard/src/Components/Header/Header.tsx @@ -245,7 +245,7 @@ const DashboardHeader: FunctionComponent = ( props.selectedProject.paymentProviderPlanId, getAllEnvVars() ) ? ( - + ) : ( <> )} diff --git a/Dashboard/src/Components/Header/Upgrade.tsx b/Dashboard/src/Components/Header/Upgrade.tsx index de91e6386b..d06056ce01 100644 --- a/Dashboard/src/Components/Header/Upgrade.tsx +++ b/Dashboard/src/Components/Header/Upgrade.tsx @@ -2,7 +2,6 @@ import React, { FunctionComponent, ReactElement, useState } from 'react'; import { IconProp } from 'CommonUI/src/Components/Icon/Icon'; import ModelFormModal from 'CommonUI/src/Components/ModelFormModal/ModelFormModal'; import Project from 'Model/Models/Project'; -import ObjectID from 'Common/Types/ObjectID'; import Navigation from 'CommonUI/src/Utils/Navigation'; import { FormType } from 'CommonUI/src/Components/Forms/ModelForm'; import FormFieldSchemaType from 'CommonUI/src/Components/Forms/Types/FormFieldSchemaType'; @@ -10,13 +9,9 @@ import SubscriptionPlan from 'Common/Types/Billing/SubscriptionPlan'; import { RadioButton } from 'CommonUI/src/Components/RadioButtons/RadioButtons'; import Button, { ButtonStyleType } from 'CommonUI/src/Components/Button/Button'; import { getAllEnvVars } from 'CommonUI/src/Config'; +import DashboardNavigation from '../../Utils/Navigation'; -export interface ComponentProps { - projectId: ObjectID; -} -const Upgrade: FunctionComponent = ( - props: ComponentProps -): ReactElement => { +const Upgrade: FunctionComponent = (): ReactElement => { const [showModal, setShowModal] = useState(false); const [isSubsriptionPlanYearly, setIsSubscriptionPlanYearly] = useState(true); @@ -39,7 +34,7 @@ const Upgrade: FunctionComponent = ( modelType={Project} title="Change Plan" name="Change Plan" - modelIdToEdit={props.projectId} + modelIdToEdit={DashboardNavigation.getProjectId()!} onClose={() => { setShowModal(false); }} diff --git a/Dashboard/src/Pages/StatusPages/View/PrivateUser.tsx b/Dashboard/src/Pages/StatusPages/View/PrivateUser.tsx index 532a81a53f..2bbdc671c3 100644 --- a/Dashboard/src/Pages/StatusPages/View/PrivateUser.tsx +++ b/Dashboard/src/Pages/StatusPages/View/PrivateUser.tsx @@ -76,7 +76,7 @@ const StatusPageDelete: FunctionComponent = ( item: StatusPagePrivateUser ): Promise => { item.statusPageId = modelId; - item.projectId = DashboardNavigation.getProjectId(); + item.projectId = DashboardNavigation.getProjectId()!; return Promise.resolve(item); }} cardProps={{ diff --git a/install.sh b/install.sh index 6dc8e61626..6dbe4478c6 100755 --- a/install.sh +++ b/install.sh @@ -13,11 +13,12 @@ sudo docker compose pull # Create database if it does not exists sudo docker compose up -d postgres && sleep 30 && sudo docker compose exec postgres psql postgresql://$DATABASE_USERNAME:$DATABASE_PASSWORD@localhost:5432/postgres -c 'CREATE DATABASE oneuptimedb' || echo "Database created" -# echo "Checking if async migrations are up to date" -# sudo -E docker compose run init - +# Start all containers. npm run start +# Restart nginx just incase the config changes. +sudo docker compose restart nginx + echo "We will need to wait ~5-10 minutes for things to settle down, migrations to finish, and TLS certs to be issued" echo "" echo "⏳ Waiting for OneUptime to boot (this will take a few minutes)"