Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
bowatts authored Jan 15, 2025
2 parents 4b90dd8 + b72010d commit 98758e8
Show file tree
Hide file tree
Showing 45 changed files with 166 additions and 57 deletions.
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,13 @@
#Replace with CIPPREadMe
![CyberDrain Light](github_assets/img/CIPP.png#gh-dark-mode-only)
![CyberDrain Dark](github_assets/img/CIPP-Light.png#gh-light-mode-only)

# What is this?

The CyberDrain Improved Partner Portal is a portal to help manage administration for Microsoft Partners. The current Microsoft partner landscape makes it fairly hard to manage multi tenant situations, with loads of manual work. Microsoft Lighthouse might resolve this in the future but development of this is lagging far behind development of the current market for Microsoft Partners.
This project is a way to help you with administration, with user management, and deploying your own preferred standards. It's not a replacement for security tools, or a way to cut costs on specific subscriptions. The tool should assist you in removing the gripes with standard partner management and save you several hours per engineer per month.
For more information, we recommend checking out our website [here](https://cipp.app)
For detailed documentation about features of CIPP, please check out our [documentation.](https://docs.cipp.app)

# Our sponsors

You can find our sponsors [here.](https://docs.cipp.app/#our-sponsors)
9 changes: 6 additions & 3 deletions Tools/Start-CippDevEmulatorsWithKitty.ps1
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
Get-Command kitty -ErrorAction Stop | Out-Null
Write-Host 'Starting CIPP Dev Emulators'
Get-Process node -ErrorAction SilentlyContinue | Stop-Process -ErrorAction SilentlyContinue
$Path = (Get-Item $PSScriptRoot).Parent.Parent.FullName

pwsh -file (Join-Path $PSScriptRoot 'Start-CippDevInstallation.ps1')

Write-Host 'Starting CIPP Dev Emulators'

if (Test-Path (Join-Path $Path 'CIPP-API-Processor')) {
$Process = Read-Host -Prompt 'Start Process Function (y/N)?'
}
Expand All @@ -11,14 +14,14 @@ if ($Process -eq 'y') {
kitty --detach --title 'CIPP' -o allow_remote_control=yes -- pwsh -c "
kitty @new-window --new-tab --tab-title `"Azurite`" --cwd $Path -- azurite ;
kitty @new-window --new-tab --tab-title `"FunctionApp`" --cwd (Join-Path $Path `"CIPP-API`") -- func start;
kitty @new-window --new-tab --tab-title `"CIPP Frontend`" --cwd (Join-Path $Path `"CIPP`") -- npm run dev ;
kitty @new-window --new-tab --tab-title `"CIPP Frontend`" --cwd (Join-Path $Path `"CIPP`") -- yarn run dev ;
kitty @new-window --new-tab --tab-title `"SWA`" --cwd (Join-Path $Path `"CIPP`") -- npm run start-swa;
kitty @new-window --new-tab --tab-title `"CIPP-API-Processor`" --cwd (Join-Path $Path `"CIPP-API-Processor`") -- func start --port 7072"

} else {
kitty --detach --title 'CIPP' -o allow_remote_control=yes -- pwsh -c "
kitty @new-window --new-tab --tab-title `"Azurite`" --cwd $Path -- azurite ;
kitty @new-window --new-tab --tab-title `"FunctionApp`" --cwd (Join-Path $Path `"CIPP-API`") -- func start;
kitty @new-window --new-tab --tab-title `"CIPP Frontend`" --cwd (Join-Path $Path `"CIPP`") -- npm run dev ;
kitty @new-window --new-tab --tab-title `"CIPP Frontend`" --cwd (Join-Path $Path `"CIPP`") -- yarn run dev ;
kitty @new-window --new-tab --tab-title `"SWA`" --cwd (Join-Path $Path `"CIPP`") -- npm run start-swa"
}
32 changes: 32 additions & 0 deletions Tools/Start-CippDevInstallation.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
$Path = (Get-Item $PSScriptRoot).Parent.Parent.FullName

if (-not(Get-Command npm)) {
throw 'npm is required to install the CIPP development environment'
}

if (-not(Get-Command azurite)) {
Write-Host 'Installing Azurite'
npm install --global 'azurite'
}

if (-not(Get-Command swa)) {
Write-Host 'Installing @azure/static-web-apps-cli'
npm install --global '@azure/static-web-apps-cli'
}

if (-not(Get-Command func)) {
Write-Host 'Installing Azure Functions Core Tools'
npm install --global 'azure-functions-core-tools@4' --unsafe-perms true
}

if (-not(Get-Command yarn)) {
Write-Host 'Installing Yarn'
npm install --global yarn
}

if (-not(yarn list --global --pattern 'next' | Select-String -Pattern 'next')) {
Write-Host 'Installing Next.js'
yarn install --global next --network-timeout 500000
}

yarn install --cwd (Join-Path $Path "CIPP") --network-timeout 500000
3 changes: 2 additions & 1 deletion deployment/AzureDeploymentTemplate.json
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,8 @@
"buildProperties": {
"appLocation": "/",
"apiLocation": "",
"appArtifactLocation": ""
"appArtifactLocation": "",
"outputLocation": "/out"
}
},
"sku": {
Expand Down
3 changes: 2 additions & 1 deletion deployment/AzureDeploymentTemplate_regionoptions.json
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,8 @@
"buildProperties": {
"appLocation": "/",
"apiLocation": "",
"appArtifactLocation": ""
"appArtifactLocation": "",
"outputLocation": "/out"
}
},
"sku": {
Expand Down
3 changes: 2 additions & 1 deletion deployment/DevAzureDeploymentTemplate_regionoptions.json
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,8 @@
"buildProperties": {
"appLocation": "/",
"apiLocation": "",
"appArtifactLocation": ""
"appArtifactLocation": "",
"outputLocation": "/out"
}
},
"sku": {
Expand Down
Binary file added github_assets/img/CIPP-Light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/CIPP.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/CyberDrain.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/Genuine-logo-vertical-light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/Huntress.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/Immybot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/Logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/NinjaOne-Dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/NinjaOne-Light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions github_assets/img/halopsa-red-grey.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/oitpsonsor_light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/img/oitpsonsor_light.webp
Binary file not shown.
Binary file added github_assets/img/profilepic.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/screenshots/AssignLicense.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/screenshots/IntunePolicyEngine.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/screenshots/MyChocoApp.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/screenshots/OffboardUser.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/screenshots/SetStandard.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added github_assets/screenshots/Teams.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion public/version.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"version": "7.0.1"
"version": "7.0.3"
}
20 changes: 14 additions & 6 deletions src/components/CippCards/CippInfoBar.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Card, Stack, SvgIcon, Typography, Skeleton } from "@mui/material";
import { Box, Card, Stack, SvgIcon, Typography, Skeleton } from "@mui/material";
import Grid from "@mui/material/Grid";

export const CippInfoBar = ({ data, isFetching }) => (
Expand Down Expand Up @@ -31,17 +31,25 @@ export const CippInfoBar = ({ data, isFetching }) => (
}}
>
<Stack alignItems="center" direction="row" spacing={2} sx={{ p: 2 }}>
<SvgIcon color={item.color ? item.color : "primary"} fontSize="small">
{item.icon}
</SvgIcon>
<div>
{item?.icon && (
<SvgIcon color={item.color ? item.color : "primary"} fontSize="small">
{item.icon}
</SvgIcon>
)}
<Box
sx={() => {
if (!item?.icon) {
return { pl: 2 };
}
}}
>
<Typography color="text.secondary" variant="overline">
{item.name}
</Typography>
<Typography variant="h6">
{isFetching ? <Skeleton width={"100%"} /> : item.data}
</Typography>
</div>
</Box>
</Stack>
</Grid>
))}
Expand Down
8 changes: 8 additions & 0 deletions src/components/CippCards/CippPropertyListCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ export const CippPropertyListCard = (props) => {
const firstHalf = propertyItems.slice(0, half);
const secondHalf = propertyItems.slice(half, propertyItems.length);

const isLabelPresent = (item) => {
return item?.label === "" || item?.label === undefined || item?.label === null;
};

const setPadding = isLabelPresent ? { py: 0.5, px: 3 } : { py: 1.5, px: 3 };

return (
<>
<Card sx={cardSx} {...other}>
Expand All @@ -56,6 +62,7 @@ export const CippPropertyListCard = (props) => {
align={align}
label={item.label}
value={<Skeleton width={280} />}
sx={setPadding}
/>
))}
</>
Expand All @@ -66,6 +73,7 @@ export const CippPropertyListCard = (props) => {
divider={showDivider}
copyItems={copyItems}
key={`${index}-index-PropertyListOffCanvas`}
sx={setPadding}
{...item}
/>
))
Expand Down
15 changes: 15 additions & 0 deletions src/components/CippComponents/CippPropertyList.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ export const CippPropertyList = (props) => {
const firstHalf = propertyItems.slice(0, half);
const secondHalf = propertyItems.slice(half, propertyItems.length);

const isLabelPresent = (item) => {
return item?.label === "" || item?.label === undefined || item?.label === null;
};

const setPadding = isLabelPresent ? { py: 0.5, px: 3 } : { py: 1.5, px: 3 };
return (
<>
{layout === "single" ? (
Expand All @@ -28,6 +33,7 @@ export const CippPropertyList = (props) => {
align={align}
label={item.label}
value={<Skeleton width={280} />}
sx={setPadding}
{...item}
/>
))}
Expand All @@ -39,6 +45,7 @@ export const CippPropertyList = (props) => {
divider={showDivider}
copyItems={copyItems}
key={`${index}-index-PropertyListOffCanvas`}
sx={setPadding}
{...item}
/>
))
Expand Down Expand Up @@ -69,6 +76,7 @@ export const CippPropertyList = (props) => {
align={align}
label={item.label}
value={<Skeleton width={280} />}
sx={setPadding}
/>
))}
</>
Expand All @@ -79,6 +87,7 @@ export const CippPropertyList = (props) => {
divider={showDivider}
copyItems={copyItems}
key={`${index}-index-PropertyListOffCanvas`}
sx={setPadding}
{...item}
/>
))
Expand All @@ -93,6 +102,11 @@ export const CippPropertyList = (props) => {
align={align}
label={item.label}
value={<Skeleton width={280} />}
sx={() => {
if (item?.label === "" || item?.label === undefined || item?.label === null) {
return { py: 0 };
}
}}
/>
))}
</>
Expand All @@ -103,6 +117,7 @@ export const CippPropertyList = (props) => {
divider={showDivider}
copyItems={copyItems}
key={`${index}-index-PropertyListOffCanvas`}
sx={setPadding}
{...item}
/>
))
Expand Down
13 changes: 9 additions & 4 deletions src/components/CippComponents/CippTenantSelector.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,11 @@ export const CippTenantSelector = (props) => {
? {
value: tenant,
label: `${matchingTenant.displayName} (${tenant})`,
addedFields: {
defaultDomainName: matchingTenant.defaultDomainName,
displayName: matchingTenant.displayName,
customerId: matchingTenant.customerId,
},
}
: {
value: null,
Expand Down Expand Up @@ -183,7 +188,7 @@ export const CippTenantSelector = (props) => {
actions={[
{
label: "M365 Admin Portal",
link: `https://admin.microsoft.com/Partner/BeginClientSession.aspx?CTID=${currentTenant?.value}&CSDEST=o365admincenter`,
link: `https://admin.microsoft.com/Partner/BeginClientSession.aspx?CTID=${currentTenant?.addedFields?.customerId}&CSDEST=o365admincenter`,
icon: <GlobeAltIcon />,
},
{
Expand Down Expand Up @@ -213,17 +218,17 @@ export const CippTenantSelector = (props) => {
},
{
label: "Sharepoint Portal",
link: `https://admin.microsoft.com/Partner/beginclientsession.aspx?CTID=${currentTenant?.value}&CSDEST=SharePoint`,
link: `https://admin.microsoft.com/Partner/beginclientsession.aspx?CTID=${currentTenant?.addedFields?.customerId}&CSDEST=SharePoint`,
icon: <Share />,
},
{
label: "Security Portal",
link: `https://security.microsoft.com/?tid=${currentTenant?.value}`,
link: `https://security.microsoft.com/?tid=${currentTenant?.addedFields?.customerId}`,
icon: <Shield />,
},
{
label: "Compliance Portal",
link: `https://compliance.microsoft.com/?tid=${currentTenant?.value}`,
link: `https://purview.microsoft.com/?tid=${currentTenant?.addedFields?.customerId}`,
icon: <ShieldMoon />,
},
]}
Expand Down
9 changes: 5 additions & 4 deletions src/components/CippFormPages/CippExchangeSettingsForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -244,12 +244,13 @@ const CippExchangeSettingsForm = (props) => {
label="Add Access"
name="calendar.UserToGetPermissions"
isFetching={isFetching || usersList.isFetching}
options={
usersList?.data?.Results?.map((user) => ({
options={[
{ value: "Default", label: "Default (Default)" },
...(usersList?.data?.Results?.map((user) => ({
value: user.userPrincipalName,
label: `${user.displayName} (${user.userPrincipalName})`,
})) || []
}
})) || []),
]}
multiple={false}
formControl={formControl}
/>
Expand Down
4 changes: 2 additions & 2 deletions src/components/CippSettings/CippCustomRoles.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ export const CippCustomRoles = () => {
alltenant = true;
}
});
if (alltenant && (blockedTenants?.length === 0 || !blockedTenants)) {
if (alltenant) {
setAllTenantSelected(true);
} else {
setAllTenantSelected(false);
Expand Down Expand Up @@ -299,7 +299,7 @@ export const CippCustomRoles = () => {
name="allowedTenants"
fullWidth={true}
/>
{allTenantSelected && (
{allTenantSelected && blockedTenants?.length == 0 && (
<Alert color="warning">
All tenants selected, no tenant restrictions will be applied unless blocked tenants
are specified.
Expand Down
14 changes: 5 additions & 9 deletions src/components/property-list-item.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,15 @@ export const PropertyListItem = (props) => {
value = "",
type,
copyItems,
sx = {
px: 3,
py: 1.5,
},
...other
} = props;
const [showPassword, setShowPassword] = useState(false);
return (
<ListItem
component={component}
disableGutters
sx={{
px: 3,
py: 1.5,
}}
{...other}
>
<ListItem component={component} disableGutters sx={sx} {...other}>
<ListItemText
disableTypography
primary={
Expand Down
Loading

0 comments on commit 98758e8

Please sign in to comment.