Skip to content

Commit

Permalink
Merge pull request #942 from OpenSourceBrain/release/0.8.0
Browse files Browse the repository at this point in the history
Release/0.8.0
  • Loading branch information
filippomc authored Feb 3, 2025
2 parents b293f8c + a521a01 commit 45825f4
Show file tree
Hide file tree
Showing 50 changed files with 2,279 additions and 382 deletions.
46 changes: 46 additions & 0 deletions .github/workflows/deploy-dev.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Build and Deploy OSBv2 to Dev
on:
push:
branches: [ develop, release/* ]

jobs:
prepare:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/checkout@v2
name: Post main clone
with:
name: MetaCell/cloud-harness
ref: ${{ vars.CLOUDHARNESS_BRANCH || 'master' }}

- uses: actions/setup-python@v5
with:
python-version: '3.9'
- name: Prepare helm chart
run: |
bash cloud-harness/install.sh
harness-deployment cloud-harness . -d ${{vars.DOMAIN}} -r ${{vars.REGISTRY}} -rs ${{secrets.REGISTRY_SECRET}}
-n ${{vars.NAMESPACE}} --write-env -e dev -i osb-portal
- uses: actions/upload-artifact@v4
with:
name: env_vars_to_export
path: deployment/.env
build-base-images:
runs-on: ubuntu-latest
steps:

- name: Build the Docker image
run: |
cd applications/nwb-explorer
docker build -t mynwbexplorer -f Dockerfile --no-cache .
- name: Deploy to Dev
uses: MetaCell/deploy-osbv2@v1
with:
environment: dev
service: nwbexplorer
port: 80
dependencies: jupyterhub
git:

2 changes: 1 addition & 1 deletion applications/common/deploy/values.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
harness:
env:
- name: SENTRY_DSN
value: https://fc2326dc50e34ac2b7188130e173f002@sentry.metacell.us/5
value: https://fc2326dc50e34ac2b7188130e173f002@o4506739169951744.ingest.us.sentry.io/4506758817382400
3 changes: 3 additions & 0 deletions applications/jupyterlab/deploy/values-quick.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
harness:
deployment:
image: gcr.io/metacellllc/osb/netpyne:0.7.6.2
2 changes: 1 addition & 1 deletion applications/netpyne/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM gcr.io/metacellllc/netpyne-ui:1.1.0
FROM gcr.io/metacellllc/netpyne-ui:1.1.1

COPY overrides/requirements.txt overrides/requirements.txt
RUN --mount=type=cache,target=/root/.cache python -m pip install --upgrade pip &&\
Expand Down
3 changes: 3 additions & 0 deletions applications/netpyne/deploy/values-quick.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
harness:
deployment:
image: gcr.io/metacellllc/osb/netpyne:0.7.6.2
1 change: 0 additions & 1 deletion applications/netpyne/deploy/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ harness:
name: proxy-public
deployment:
auto: false
image: netpyne:latest
jupyterhub:
args: ["--NotebookApp.default_url=/geppetto", "--library=netpyne_ui", "--NotebookApp.notebook_dir=/opt/workspace", "--NotebookApp.disable_check_xsrf=True"]
applicationHook: "osb_jupyter.change_pod_manifest"
Expand Down
7 changes: 6 additions & 1 deletion applications/nfsserver/deploy/values.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@

harness:
deployment:
auto: false
image: gcr.io/metacellllc/osb/nfsserver:0.7.6
# nfs server pvc disk size (/exports)
server:
diskSize: 120Gi
diskSize: 240Gi
5 changes: 5 additions & 0 deletions applications/nwb-explorer/deploy/values-quick.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
harness:
deployment:
image: gcr.io/metacellllc/osb/nwb-explorer:0.7.6.2
dependencies: {}

2 changes: 1 addition & 1 deletion applications/nwb-explorer/deploy/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ harness:
dependencies:
git:
- url: https://github.com/MetaCell/nwb-explorer.git
branch_tag: development
branch_tag: master
jupyterhub:
args: ["--debug", "--NotebookApp.default_url=/geppetto", "--library=nwb_explorer", "--NotebookApp.notebook_dir=/opt/workspace"]
applicationHook: "osb_jupyter.change_pod_manifest"
Expand Down
2 changes: 1 addition & 1 deletion applications/osb-portal/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "frontend",
"version": "0.7.0",
"version": "0.8.0",
"description": "",
"main": "index.js",
"scripts": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ apis/K8sApi.ts
apis/RestApi.ts
apis/index.ts
index.ts
models/BiomodelsRepositoryResource.ts
models/DandiRepositoryResource.ts
models/DownloadResource.ts
models/FigshareRepositoryResource.ts
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
/* tslint:disable */
/* eslint-disable */
/**
* OSB Workspaces manager API
* Opensource Brain Platform - Reference Workspaces manager API
*
* The version of the OpenAPI document: 0.2.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/

import { exists, mapValues } from '../runtime';
import {
RepositoryResourceBase,
RepositoryResourceBaseFromJSON,
RepositoryResourceBaseFromJSONTyped,
RepositoryResourceBaseToJSON,
} from './';

/**
* figshare repository resource
* @export
* @interface BiomodelsRepositoryResource
*/
export interface BiomodelsRepositoryResource {
/**
* file name
* @type {string}
* @memberof BiomodelsRepositoryResource
*/
name?: string;
/**
* Download URL of the Resource
* @type {string}
* @memberof BiomodelsRepositoryResource
*/
path?: string;
/**
* OSB Repository id
* @type {number}
* @memberof BiomodelsRepositoryResource
*/
osbrepositoryId?: number;
/**
* File size in bytes of the RepositoryResource
* @type {number}
* @memberof BiomodelsRepositoryResource
*/
size?: number;
/**
* Date/time the ReposityResource is last modified
* @type {Date}
* @memberof BiomodelsRepositoryResource
*/
timestampModified?: Date;
}

export function BiomodelsRepositoryResourceFromJSON(json: any): BiomodelsRepositoryResource {
return BiomodelsRepositoryResourceFromJSONTyped(json, false);
}

export function BiomodelsRepositoryResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): BiomodelsRepositoryResource {
if ((json === undefined) || (json === null)) {
return json;
}
return {

'name': !exists(json, 'name') ? undefined : json['name'],
'path': !exists(json, 'path') ? undefined : json['path'],
'osbrepositoryId': !exists(json, 'osbrepository_id') ? undefined : json['osbrepository_id'],
'size': !exists(json, 'size') ? undefined : json['size'],
'timestampModified': !exists(json, 'timestamp_modified') ? undefined : (new Date(json['timestamp_modified'])),
};
}

export function BiomodelsRepositoryResourceToJSON(value?: BiomodelsRepositoryResource | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {

'name': value.name,
'path': value.path,
'osbrepository_id': value.osbrepositoryId,
'size': value.size,
'timestamp_modified': value.timestampModified === undefined ? undefined : (value.timestampModified.toISOString()),
};
}


Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
export enum RepositoryType {
Dandi = 'dandi',
Figshare = 'figshare',
Github = 'github'
Github = 'github',
Biomodels = 'biomodels'
}

export function RepositoryTypeFromJSON(json: any): RepositoryType {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
export * from './BiomodelsRepositoryResource';
export * from './DandiRepositoryResource';
export * from './DownloadResource';
export * from './FigshareRepositoryResource';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import SearchIcon from "@mui/icons-material/Search";
//style
import { bgRegular, chipTextColor } from "../../theme";
import styled from "@mui/system/styled";
import { debounce } from "lodash";

const StyledTextField = styled(TextField)(({ theme }) => ({
backgroundColor: bgRegular,
Expand Down Expand Up @@ -44,21 +45,24 @@ interface RepositoriesSearchProps {
}

export default (props: RepositoriesSearchProps) => {

const handleChange = React.useCallback(debounce((event: React.ChangeEvent<HTMLInputElement>) => {
// Timout improves responsiveness while typing
props.filterChanged(event.target.value);
}, 1000), []);

return (
<StyledTextField
variant="standard"
id="standard-start-adornment"
fullWidth={true}
value={props?.value}
sx={{
borderRadius: props?.borderRadius
? `${props?.borderRadius}px`
: "8px 0px 0px 8px",
}}
placeholder="Search"
onChange={(e) => {
props.filterChanged(e.target.value.toLowerCase());
}}
onChange={handleChange}
InputProps={{
startAdornment: (
<InputAdornment position="start">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,9 +181,14 @@ export const SearchFilterReposWorkspaces = (
}
);
}, 500),
[]
);
[] );

const handleTagsChange = React.useCallback((event, value) => props?.setSearchFilterValues({
...props?.searchFilterValues,
tags: value,
})
, [props?.searchFilterValues]);

return (
<>
<RepositoriesWorkspacesSearchField value={props.searchFilterValues.text} filterChanged={props?.filterChanged} />
Expand Down Expand Up @@ -223,12 +228,7 @@ export const SearchFilterReposWorkspaces = (
onInputChange={(event, value) => {
handleTagInput(value);
}}
onChange={(event, value) =>
props?.setSearchFilterValues({
...props?.searchFilterValues,
tags: value,
})
}
onChange={handleTagsChange}
onClose={(event, reason) => handleTagInput("")}
renderTags={(value, getTagProps) =>
value.map((option, index) => (
Expand Down Expand Up @@ -309,6 +309,8 @@ export const SearchFilterReposWorkspaces = (
</StyledPopover>
</>
);


};

export default SearchFilterReposWorkspaces;
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ import { RepositoryType } from "../../apiclient/workspaces";
export default {
[RepositoryType.Dandi]: "DANDI Archive",
[RepositoryType.Github]: "GitHub",
[RepositoryType.Biomodels]: "Biomodels",
} as any;
Loading

0 comments on commit 45825f4

Please sign in to comment.