├── docs ├── static │ ├── .nojekyll │ └── img │ │ ├── flow.png │ │ ├── gcp.png │ │ ├── icon.png │ │ ├── logo.png │ │ ├── quick.png │ │ ├── favicon.ico │ │ ├── customize.png │ │ ├── settings.png │ │ ├── architecture.png │ │ ├── web_settings.png │ │ ├── collaboration.png │ │ ├── favicon-16x16.png │ │ ├── favicon-32x32.png │ │ ├── add_firebase_one.png │ │ ├── add_firebase_two.png │ │ ├── apple-touch-icon.png │ │ └── android-chrome-96x96.png ├── babel.config.js ├── src │ ├── pages │ │ ├── markdown-page.md │ │ ├── index.module.css │ │ └── index.tsx │ ├── components │ │ └── HomepageFeatures │ │ │ └── styles.module.css │ └── css │ │ └── custom.css ├── tsconfig.json ├── docs │ ├── terraform-cli │ │ ├── _category_.json │ │ ├── cli_configure │ │ │ ├── _category_.json │ │ │ └── customizing-modules.md │ │ ├── cli_deployment │ │ │ └── _category_.json │ │ └── cli_installation │ │ │ ├── _category_.json │ │ │ └── source-control.md │ ├── rad-lab-ui │ │ ├── troubleshooting.md │ │ ├── ui_configure │ │ │ ├── _category_.json │ │ │ └── customizing-modules.md │ │ ├── ui_deployment │ │ │ ├── _category_.json │ │ │ ├── update-a-module.md │ │ │ └── delete-a-module.md │ │ ├── _category_.json │ │ └── ui_installation │ │ │ ├── _category_.json │ │ │ └── cleanup.md │ ├── rad-lab-launcher │ │ ├── launcher_configure │ │ │ ├── _category_.json │ │ │ └── customizing-modules.md │ │ ├── _category_.json │ │ ├── launcher_deployment │ │ │ └── _category_.json │ │ └── launcher_installation │ │ │ └── _category_.json │ └── getting-started.md ├── .gitignore ├── sidebars.js ├── README.md └── package.json ├── radlab-ui ├── automation │ ├── terraform │ │ ├── .gitkeep │ │ ├── infrastructure │ │ │ ├── function │ │ │ │ ├── delete_deployment │ │ │ │ │ └── package.json │ │ │ │ └── create_deployment │ │ │ │ │ └── package.json │ │ │ ├── templates │ │ │ │ ├── backend.tf.tpl │ │ │ │ └── app.yaml.tpl │ │ │ └── versions.tf │ │ └── modules │ │ │ ├── tf-builder │ │ │ ├── outputs.tf │ │ │ ├── entrypoint.bash │ │ │ ├── versions.tf │ │ │ ├── scripts │ │ │ │ └── build_container.sh │ │ │ ├── variables.tf │ │ │ ├── main.tf │ │ │ └── Dockerfile │ │ │ └── project │ │ │ ├── versions.tf │ │ │ ├── iam.tf │ │ │ └── README.md │ ├── package.json │ └── cloudbuild_delete_deployment.yaml ├── webapp │ ├── jest.env.js │ ├── .dockerignore │ ├── firestore.indexes.json │ ├── public │ │ ├── locales │ │ │ ├── en │ │ │ │ ├── home.json │ │ │ │ └── signin.json │ │ │ └── es │ │ │ │ ├── home.json │ │ │ │ └── signin.json │ │ ├── favicon.ico │ │ ├── favicon-16x16.png │ │ ├── favicon-32x32.png │ │ ├── mstile-150x150.png │ │ ├── apple-touch-icon.png │ │ ├── assets │ │ │ ├── images │ │ │ │ ├── gcp.png │ │ │ │ ├── admin.png │ │ │ │ ├── icon.png │ │ │ │ ├── logo.png │ │ │ │ ├── access.png │ │ │ │ ├── gcp_orig.png │ │ │ │ ├── google.png │ │ │ │ └── empty_state.png │ │ │ └── htmlTemplates │ │ │ │ ├── deleteEmail.html │ │ │ │ └── email.html │ │ ├── android-chrome-96x96.png │ │ ├── browserconfig.xml │ │ ├── site.webmanifest │ │ └── safari-pinned-tab.svg │ ├── src │ │ ├── utils │ │ │ ├── sorting.ts │ │ │ ├── dom.ts │ │ │ ├── routing.ts │ │ │ ├── env.ts │ │ │ ├── firebaseAdmin.ts │ │ │ ├── firebase.ts │ │ │ ├── deployments.ts │ │ │ ├── AppConfig.ts │ │ │ ├── cloud.ts │ │ │ └── validation.ts │ │ ├── store │ │ │ ├── index.ts │ │ │ ├── cloudLocation.ts │ │ │ ├── alert.ts │ │ │ └── user.ts │ │ ├── pages │ │ │ ├── api │ │ │ │ ├── firebaseAdminConnection.ts │ │ │ │ ├── user.ts │ │ │ │ ├── github │ │ │ │ │ ├── modules.ts │ │ │ │ │ └── [moduleName] │ │ │ │ │ │ └── variables.ts │ │ │ │ └── regions.ts │ │ │ ├── ThemeChanger.tsx │ │ │ ├── index.tsx │ │ │ ├── _document.tsx │ │ │ ├── _app.tsx │ │ │ └── password-reset.tsx │ │ ├── routes │ │ │ ├── AdminRoutes.tsx │ │ │ ├── Home.tsx │ │ │ ├── SignOut.tsx │ │ │ └── NotFound.tsx │ │ ├── components │ │ │ ├── RouteContainer.tsx │ │ │ ├── SectionHeader.tsx │ │ │ ├── LoadingRow.tsx │ │ │ ├── modules │ │ │ │ ├── ModuleOverviewCard.tsx │ │ │ │ └── PublishModule.tsx │ │ │ ├── NewDeploymentButton.tsx │ │ │ ├── AdminSettingsButton.tsx │ │ │ ├── forms │ │ │ │ └── fields │ │ │ │ │ ├── BooleanField.tsx │ │ │ │ │ ├── NumberField.tsx │ │ │ │ │ ├── StringField.tsx │ │ │ │ │ ├── RegionStringField.tsx │ │ │ │ │ └── ZoneStringField.tsx │ │ │ ├── EmptyState.tsx │ │ │ ├── EmptyAdminState.tsx │ │ │ └── ProjectLink.tsx │ │ ├── styles │ │ │ ├── themes.js │ │ │ └── global.css │ │ ├── templates │ │ │ ├── Unauthenticated.tsx │ │ │ └── Main.tsx │ │ ├── navigation │ │ │ └── Loading.tsx │ │ └── context │ │ │ └── auth.tsx │ ├── README.md │ ├── next-i18next.config.js │ ├── firestore.rules │ ├── storage.rules │ ├── lint-staged.config.js │ ├── Dockerfile │ ├── next-env.d.ts │ ├── postcss.config.js │ ├── setup-tests.ts │ ├── __mocks__ │ │ ├── deployments.ts │ │ ├── default.ts │ │ └── user.ts │ ├── .gcloudignore │ ├── firebase.json │ ├── __tests__ │ │ ├── utils │ │ │ ├── env.test.ts │ │ │ └── validation.test.ts │ │ ├── components │ │ │ ├── routeContainer.test.tsx │ │ │ ├── sectionheader.test.tsx │ │ │ ├── loadingRow.test.tsx │ │ │ ├── emptyState.test.tsx │ │ │ ├── newDeploymentButton.test.tsx │ │ │ ├── emptyAdminState.test.tsx │ │ │ └── adminsettingsbutton.test.tsx │ │ ├── routes │ │ │ ├── admin.test.tsx │ │ │ ├── deployments.test.tsx │ │ │ └── publish.test.tsx │ │ └── navigation │ │ │ └── footer.test.tsx │ ├── .env.development │ ├── .env.production │ ├── app.yaml.example │ ├── next.config.js │ ├── .env.test │ ├── jest.config.js │ └── tsconfig.json ├── .prettierrc ├── .editorconfig └── firestore-schema.json ├── modules ├── secure_data_warehouse │ ├── templates │ │ ├── schema.tpl │ │ ├── deidentification.tpl │ │ ├── schema_template.tpl │ │ └── deidentification_template.tpl │ ├── images │ │ └── architecture.png │ ├── scripts │ │ └── build │ │ │ └── wrapped-key │ │ │ └── requirements.txt │ ├── versions.tf │ ├── provider-auth.tf │ └── network.tf ├── NEON │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── neon_notebooks.tf │ ├── scripts │ │ ├── usage │ │ │ └── README.md │ │ └── build │ │ │ └── startup_script.sh │ └── provider-auth.tf ├── gen_ai │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── scripts │ │ ├── usage │ │ │ └── README.md │ │ └── build │ │ │ └── startup_script.sh │ └── provider-auth.tf ├── silicon │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── scripts │ │ ├── build │ │ │ └── images │ │ │ │ ├── provision │ │ │ │ └── profile.sh │ │ │ │ └── Dockerfile │ │ └── usage │ │ │ └── README.md │ └── provider-auth.tf ├── web_hosting │ ├── scripts │ │ └── build │ │ │ ├── startup_scripts │ │ │ └── sample_app │ │ │ │ ├── requirements.txt │ │ │ │ ├── templates │ │ │ │ ├── index.html │ │ │ │ ├── delete.html │ │ │ │ ├── create.html │ │ │ │ └── base.html │ │ │ │ └── sample_app.sh.tpl │ │ │ └── img │ │ │ └── clear-day-brock-mountain-drive_800.jpg │ ├── images │ │ └── architecture.png │ ├── versions.tf │ └── provider-auth.tf ├── alpha_fold │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── scripts │ │ └── build │ │ │ └── startup_script.sh │ └── provider-auth.tf ├── data_science │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── samplenotebooks.tf │ ├── scripts │ │ ├── usage │ │ │ └── README.md │ │ └── build │ │ │ └── startup_script.sh │ └── provider-auth.tf ├── genomics_dsub │ ├── images │ │ └── architecture.png │ ├── scripts │ │ └── build │ │ │ ├── cloud_functions │ │ │ └── function-source │ │ │ │ └── requirements.txt │ │ │ └── container │ │ │ └── fastqc-0.11.9a │ │ │ ├── Dockerfile │ │ │ ├── cloudbuild.yaml │ │ │ └── build-container.sh │ ├── versions.tf │ ├── outputs.tf │ └── provider-auth.tf ├── app_mod_elastic │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── scripts │ │ └── build │ │ │ └── remove_eck_operator.sh │ ├── outputs.tf │ ├── provider-auth.tf │ └── templates │ │ └── elastic_search_deployment.yaml.tpl ├── billing_budget │ ├── images │ │ └── architecture.png │ ├── versions.tf │ ├── scripts │ │ └── build │ │ │ └── sample_startup_script.sh.tpl │ └── provider-auth.tf ├── genomics_cromwell │ ├── images │ │ └── architecture.png │ ├── scripts │ │ └── build │ │ │ └── cromwell.service │ ├── versions.tf │ └── provider-auth.tf └── genomics_nextflow │ ├── images │ └── architecture.png │ └── provider-auth.tf ├── .github ├── workflows │ ├── fake-key.json │ └── docs-test-deploy.yml └── ISSUE_TEMPLATE │ ├── ask-for-help.md │ ├── bug_report.md │ └── feature_request.md ├── tools └── requirements.txt ├── radlab-launcher ├── requirements.txt └── cloudsdk_kubectl_installer.py ├── CODEOWNERS └── .gitignore /docs/static/.nojekyll: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /modules/secure_data_warehouse/templates/schema.tpl: -------------------------------------------------------------------------------- 1 | [] -------------------------------------------------------------------------------- /modules/secure_data_warehouse/templates/deidentification.tpl: -------------------------------------------------------------------------------- 1 | {} 2 | -------------------------------------------------------------------------------- /radlab-ui/webapp/jest.env.js: -------------------------------------------------------------------------------- 1 | global.setImmediate = jest.useRealTimers; -------------------------------------------------------------------------------- /radlab-ui/webapp/.dockerignore: -------------------------------------------------------------------------------- 1 | .git 2 | dist 3 | node_modules 4 | .next 5 | -------------------------------------------------------------------------------- /radlab-ui/webapp/firestore.indexes.json: -------------------------------------------------------------------------------- 1 | { 2 | "indexes": [], 3 | "fieldOverrides": [] 4 | } 5 | -------------------------------------------------------------------------------- /radlab-ui/webapp/public/locales/en/home.json: -------------------------------------------------------------------------------- 1 | { 2 | "add-content": "Add your content here" 3 | } 4 | -------------------------------------------------------------------------------- /.github/workflows/fake-key.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "service_account", 3 | "project_id": "test-only" 4 | } -------------------------------------------------------------------------------- /radlab-ui/webapp/public/locales/es/home.json: -------------------------------------------------------------------------------- 1 | { 2 | "add-content": "Agrega tu contenido aquí" 3 | } 4 | -------------------------------------------------------------------------------- /docs/static/img/flow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/flow.png -------------------------------------------------------------------------------- /docs/static/img/gcp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/gcp.png -------------------------------------------------------------------------------- /docs/static/img/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/icon.png -------------------------------------------------------------------------------- /docs/static/img/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/logo.png -------------------------------------------------------------------------------- /docs/static/img/quick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/quick.png -------------------------------------------------------------------------------- /docs/static/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/favicon.ico -------------------------------------------------------------------------------- /radlab-ui/webapp/src/utils/sorting.ts: -------------------------------------------------------------------------------- 1 | export const alphabetically = (a: string, b: string) => a.localeCompare(b) 2 | -------------------------------------------------------------------------------- /tools/requirements.txt: -------------------------------------------------------------------------------- 1 | click 2 | python-dateutil 3 | pytz 4 | requests 5 | python-terraform>=0.10.1 6 | colorama>=0.4.4 -------------------------------------------------------------------------------- /docs/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [require.resolve('@docusaurus/core/lib/babel/preset')], 3 | }; 4 | -------------------------------------------------------------------------------- /docs/static/img/customize.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/customize.png -------------------------------------------------------------------------------- /docs/static/img/settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/settings.png -------------------------------------------------------------------------------- /radlab-ui/webapp/README.md: -------------------------------------------------------------------------------- 1 | # RAD Lab UI 2 | 3 | See documentation at: https://googlecloudplatform.github.io/rad-lab/ 4 | -------------------------------------------------------------------------------- /docs/static/img/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/architecture.png -------------------------------------------------------------------------------- /docs/static/img/web_settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/web_settings.png -------------------------------------------------------------------------------- /docs/static/img/collaboration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/collaboration.png -------------------------------------------------------------------------------- /docs/static/img/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/favicon-16x16.png -------------------------------------------------------------------------------- /docs/static/img/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/favicon-32x32.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/favicon.ico -------------------------------------------------------------------------------- /docs/static/img/add_firebase_one.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/add_firebase_one.png -------------------------------------------------------------------------------- /docs/static/img/add_firebase_two.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/add_firebase_two.png -------------------------------------------------------------------------------- /docs/static/img/apple-touch-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/apple-touch-icon.png -------------------------------------------------------------------------------- /modules/NEON/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/NEON/images/architecture.png -------------------------------------------------------------------------------- /docs/static/img/android-chrome-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/docs/static/img/android-chrome-96x96.png -------------------------------------------------------------------------------- /modules/gen_ai/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/gen_ai/images/architecture.png -------------------------------------------------------------------------------- /modules/silicon/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/silicon/images/architecture.png -------------------------------------------------------------------------------- /modules/web_hosting/scripts/build/startup_scripts/sample_app/requirements.txt: -------------------------------------------------------------------------------- 1 | flask 2 | pg8000 3 | sqlalchemy 4 | cloud-sql-python-connector -------------------------------------------------------------------------------- /modules/alpha_fold/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/alpha_fold/images/architecture.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/favicon-16x16.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/favicon-32x32.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/mstile-150x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/mstile-150x150.png -------------------------------------------------------------------------------- /modules/data_science/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/data_science/images/architecture.png -------------------------------------------------------------------------------- /modules/genomics_dsub/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/genomics_dsub/images/architecture.png -------------------------------------------------------------------------------- /modules/web_hosting/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/web_hosting/images/architecture.png -------------------------------------------------------------------------------- /radlab-ui/webapp/next-i18next.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | i18n: { 3 | defaultLocale: 'en', 4 | locales: ['en', 'es'], 5 | }, 6 | } 7 | -------------------------------------------------------------------------------- /radlab-ui/webapp/public/apple-touch-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/apple-touch-icon.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/gcp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/gcp.png -------------------------------------------------------------------------------- /modules/app_mod_elastic/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/app_mod_elastic/images/architecture.png -------------------------------------------------------------------------------- /modules/billing_budget/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/billing_budget/images/architecture.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/admin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/admin.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/icon.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/logo.png -------------------------------------------------------------------------------- /modules/genomics_cromwell/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/genomics_cromwell/images/architecture.png -------------------------------------------------------------------------------- /modules/genomics_nextflow/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/genomics_nextflow/images/architecture.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/android-chrome-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/android-chrome-96x96.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/access.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/access.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/gcp_orig.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/gcp_orig.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/google.png -------------------------------------------------------------------------------- /modules/genomics_dsub/scripts/build/cloud_functions/function-source/requirements.txt: -------------------------------------------------------------------------------- 1 | # Function dependencies, for example: 2 | # package>=version 3 | dsub==0.4.5 4 | -------------------------------------------------------------------------------- /modules/secure_data_warehouse/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/secure_data_warehouse/images/architecture.png -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/images/empty_state.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/radlab-ui/webapp/public/assets/images/empty_state.png -------------------------------------------------------------------------------- /docs/src/pages/markdown-page.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Markdown page example 3 | --- 4 | 5 | # Markdown page example 6 | 7 | You don't need React to write simple standalone pages. 8 | -------------------------------------------------------------------------------- /radlab-ui/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "tabWidth": 2, 3 | "useTabs": false, 4 | "semi": false, 5 | "trailingComma": "all", 6 | "bracketSpacing": true, 7 | "endOfLine": "lf" 8 | } 9 | -------------------------------------------------------------------------------- /radlab-ui/webapp/firestore.rules: -------------------------------------------------------------------------------- 1 | service cloud.firestore { 2 | match /databases/{database}/documents { 3 | match /{document=**} { 4 | allow read, write: if false; 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /radlab-ui/webapp/storage.rules: -------------------------------------------------------------------------------- 1 | rules_version = '2'; 2 | service firebase.storage { 3 | match /b/{bucket}/o { 4 | match /{allPaths=**} { 5 | allow read, write: if false; 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /radlab-ui/webapp/lint-staged.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | '*.{js,jsx,ts,tsx}': ['eslint --fix', 'eslint'], 3 | '**/*.ts?(x)': () => 'npm run build-types', 4 | '*.json': ['prettier --write'], 5 | }; 6 | -------------------------------------------------------------------------------- /modules/web_hosting/scripts/build/img/clear-day-brock-mountain-drive_800.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/GoogleCloudPlatform/rad-lab/HEAD/modules/web_hosting/scripts/build/img/clear-day-brock-mountain-drive_800.jpg -------------------------------------------------------------------------------- /radlab-ui/webapp/src/store/index.ts: -------------------------------------------------------------------------------- 1 | import alertStore from "./alert" 2 | import cloudLocationStore from "./cloudLocation" 3 | import userStore from "./user" 4 | 5 | export { alertStore, cloudLocationStore, userStore } 6 | -------------------------------------------------------------------------------- /radlab-launcher/requirements.txt: -------------------------------------------------------------------------------- 1 | art 2 | beautifulsoup4>=0.01 3 | requests>=2.26.0 4 | google-api-python-client>=2.17.0 5 | oauth2client>=4.1.3 6 | colorama>=0.4.4 7 | google-cloud-storage>=1.42.1 8 | python-terraform>=0.10.1 -------------------------------------------------------------------------------- /docs/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | // This file is not used in compilation. It is here just for a nice editor experience. 3 | "extends": "@tsconfig/docusaurus/tsconfig.json", 4 | "compilerOptions": { 5 | "baseUrl": "." 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /docs/docs/terraform-cli/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Terraform CLI", 3 | "position": 3, 4 | "link": { 5 | "type": "generated-index", 6 | "description": "Learn how to deploy Terraform modules to Google Cloud." 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /docs/src/components/HomepageFeatures/styles.module.css: -------------------------------------------------------------------------------- 1 | .features { 2 | display: flex; 3 | align-items: center; 4 | padding: 2rem 0; 5 | width: 100%; 6 | } 7 | 8 | .featureSvg { 9 | height: 200px; 10 | width: 200px; 11 | } 12 | -------------------------------------------------------------------------------- /radlab-ui/webapp/Dockerfile: -------------------------------------------------------------------------------- 1 | 2 | FROM node:16-alpine 3 | 4 | WORKDIR /app 5 | 6 | COPY package.json . 7 | COPY package-lock.json . 8 | 9 | RUN npm ci 10 | 11 | COPY . . 12 | 13 | EXPOSE 3000 14 | 15 | CMD [ "npm", "run", "dev" ] 16 | -------------------------------------------------------------------------------- /radlab-ui/webapp/next-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | 4 | // NOTE: This file should not be edited 5 | // see https://nextjs.org/docs/basic-features/typescript for more information. 6 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/troubleshooting.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 4 3 | --- 4 | # Troubleshooting 5 | 6 | Please feel free to reach out and to create a [GitHub issue](https://github.com/GoogleCloudPlatform/rad-lab/issues) in case of any issues or concerns. 7 | 8 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/pages/api/firebaseAdminConnection.ts: -------------------------------------------------------------------------------- 1 | import admin from "firebase-admin" 2 | import { getFirestore } from "firebase-admin/firestore" 3 | 4 | if (admin.apps.length === 0) { 5 | admin.initializeApp() 6 | } 7 | const db = getFirestore() 8 | export { db } 9 | -------------------------------------------------------------------------------- /docs/docs/terraform-cli/cli_configure/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Configure Modules", 3 | "position": 2, 4 | "link": { 5 | "slug": "cli_configure", 6 | "type": "generated-index", 7 | "description": "Learn how to customize Modules" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/ui_configure/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Configure Modules", 3 | "position": 4, 4 | "link": { 5 | "slug": "ui_configure", 6 | "type": "generated-index", 7 | "description": "Learn how to customize and extend Modules" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-launcher/launcher_configure/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Configure Modules", 3 | "position": 2, 4 | "link": { 5 | "slug": "launcher_configure", 6 | "type": "generated-index", 7 | "description": "Learn how to customize Modules" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/utils/dom.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Pass many strings and get one back. Useful for dynamic classNames 3 | * @param classes n strings 4 | * @returns A concatenated string of classes 5 | */ 6 | export const classNames = (...classes: string[]) => 7 | classes.filter(Boolean).join(" ") 8 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-launcher/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "RAD Lab Launcher", 3 | "position": 1, 4 | "link": { 5 | "type": "generated-index", 6 | "description": "The RAD Lab Launcher is the guided CLI tool built upon Python to deploy RAD Lab modules in your Google Cloud environment." 7 | } 8 | } -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/ui_deployment/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Module Deployment", 3 | "position": 3, 4 | "link": { 5 | "slug": "ui_deployment", 6 | "type": "generated-index", 7 | "description": "Learn how to deploy, update, and delete RAD Lab modules in Google Cloud" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/utils/routing.ts: -------------------------------------------------------------------------------- 1 | import { NextRouter } from "next/router" 2 | 3 | /** 4 | * @param router A React Router instance 5 | * @returns boolean. True if href matches the current route 6 | */ 7 | export const isCurrentRoute = (router: NextRouter) => (href: string) => 8 | href === router.pathname 9 | -------------------------------------------------------------------------------- /docs/docs/terraform-cli/cli_deployment/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Module Deployment", 3 | "position": 3, 4 | "link": { 5 | "slug": "cli_deployment", 6 | "type": "generated-index", 7 | "description": "Learn how to deploy, update, and delete Google Cloud modules via Terraform." 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /radlab-ui/webapp/public/browserconfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | #2b5797 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /docs/.gitignore: -------------------------------------------------------------------------------- 1 | # Dependencies 2 | /node_modules 3 | 4 | # Production 5 | /build 6 | 7 | # Generated files 8 | .docusaurus 9 | .cache-loader 10 | 11 | # Misc 12 | .DS_Store 13 | .env.local 14 | .env.development.local 15 | .env.test.local 16 | .env.production.local 17 | 18 | npm-debug.log* 19 | yarn-debug.log* 20 | yarn-error.log* 21 | -------------------------------------------------------------------------------- /radlab-ui/.editorconfig: -------------------------------------------------------------------------------- 1 | [*] 2 | charset = utf-8 3 | end_of_line = lf 4 | indent_size = 2 5 | indent_style = space 6 | insert_final_newline = true 7 | max_line_length = 80 8 | trim_trailing_whitespace = true 9 | 10 | [*.md] 11 | max_line_length = 0 12 | trim_trailing_whitespace = false 13 | 14 | [COMMIT_EDITMSG] 15 | max_line_length = 0 16 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-launcher/launcher_deployment/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Module Deployment", 3 | "position": 3, 4 | "link": { 5 | "slug": "launcher_deployment", 6 | "type": "generated-index", 7 | "description": "Learn how to deploy, update, and delete Google Cloud modules via the RAD Lab Launcher (CLI tool)." 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/store/cloudLocation.ts: -------------------------------------------------------------------------------- 1 | import { create } from "zustand" 2 | import { CloudLocation } from "@/utils/cloud" 3 | 4 | const cloudLocation = new CloudLocation() 5 | 6 | interface IState { 7 | cloudLocation: CloudLocation 8 | } 9 | 10 | const useStore = create(() => ({ 11 | cloudLocation, 12 | })) 13 | 14 | export default useStore 15 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/routes/AdminRoutes.tsx: -------------------------------------------------------------------------------- 1 | import NotAuthorized from "@/components/NotAuthorized" 2 | 3 | interface IAdmin { 4 | admin: boolean | null 5 | } 6 | 7 | const AdminRoutes: React.FC = ({ admin, children }) => { 8 | if (!admin) return 9 | return <>{children} 10 | } 11 | 12 | export default AdminRoutes 13 | -------------------------------------------------------------------------------- /radlab-ui/webapp/postcss.config.js: -------------------------------------------------------------------------------- 1 | // Please do not use the array form (like ['tailwindcss', 'postcss-preset-env']) 2 | // it will create an unexpected error: Invalid PostCSS Plugin found: [0] 3 | 4 | module.exports = { 5 | plugins: { 6 | tailwindcss: {}, 7 | autoprefixer: {}, 8 | ...(process.env.NODE_ENV === 'production' ? { cssnano: {} } : {}), 9 | }, 10 | }; 11 | -------------------------------------------------------------------------------- /radlab-ui/webapp/public/site.webmanifest: -------------------------------------------------------------------------------- 1 | { 2 | "name": "", 3 | "short_name": "", 4 | "icons": [ 5 | { 6 | "src": "/android-chrome-96x96.png", 7 | "sizes": "96x96", 8 | "type": "image/png" 9 | } 10 | ], 11 | "theme_color": "#ffffff", 12 | "background_color": "#ffffff", 13 | "display": "standalone" 14 | } 15 | -------------------------------------------------------------------------------- /modules/genomics_cromwell/scripts/build/cromwell.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=Cromwell Server 3 | After=network.target 4 | 5 | [Service] 6 | User=root 7 | Group=root 8 | Restart=always 9 | TimeoutStopSec=10 10 | RestartSec=5 11 | WorkingDirectory=/opt/cromwell 12 | ExecStart=/usr/bin/java -Xmx10G -Dconfig.file=cromwell.conf -jar cromwell.jar server 13 | 14 | [Install] 15 | WantedBy=multi-user.target -------------------------------------------------------------------------------- /radlab-ui/webapp/src/routes/Home.tsx: -------------------------------------------------------------------------------- 1 | import { useEffect } from "react" 2 | import { useNavigate } from "react-router-dom" 3 | 4 | interface HomeProps {} 5 | 6 | const Home: React.FC = () => { 7 | const navigate = useNavigate() 8 | 9 | // Route immediately to /deployments 10 | useEffect(() => navigate("/deployments"), []) 11 | 12 | return <> 13 | } 14 | 15 | export default Home 16 | -------------------------------------------------------------------------------- /docs/docs/terraform-cli/cli_installation/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Installation", 3 | "position": 1, 4 | "link": { 5 | "slug": "cli_installation", 6 | "type": "generated-index", 7 | "description": "Cloud Admins can set up a privately hosted version of RAD Lab for their organization to use. Cloud Admins can spin up the modules (GCP projects / resources within the bounds set) for their Users." 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-launcher/launcher_installation/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Installation", 3 | "position": 1, 4 | "link": { 5 | "slug": "launcher_installation", 6 | "type": "generated-index", 7 | "description": "Cloud Admins can set up a privately hosted version of RAD Lab for their organization to use. Cloud Admins can spin up the modules (GCP projects / resources within the bounds set) for their Users." 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /modules/web_hosting/scripts/build/startup_scripts/sample_app/templates/index.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 |

{% block title %} List of Users {% endblock %}

5 | {% for account in accounts %} 6 | 10 | {% endfor %} 11 | {% endblock %} -------------------------------------------------------------------------------- /radlab-ui/webapp/src/components/RouteContainer.tsx: -------------------------------------------------------------------------------- 1 | interface RouteContainerProps {} 2 | const RouteContainer: React.FC = ({ children }) => { 3 | return ( 4 |
8 |
{children}
9 |
10 | ) 11 | } 12 | 13 | export default RouteContainer 14 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "RAD Lab UI", 3 | "position": 2, 4 | "link": { 5 | "type": "generated-index", 6 | "description": "RAD Lab solution is primarily a combination of use-case based Terraform modules. As such, it may be difficult for individuals without a strong IT background. RAD Lab UI to the rescue! RAD Lab UI provides an easy to use interface to enter details about your workload and deploy with just a few clicks." 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/infrastructure/function/delete_deployment/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "delete_deployment", 3 | "version": "1.0.0", 4 | "description": "Delete a RAD Lab module deployment.", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "npm -- run unit-test" 8 | }, 9 | "author": "", 10 | "license": "Apache-2.0", 11 | "dependencies": { 12 | "@google-cloud/cloudbuild": "^3.1.0", 13 | "firebase-admin": "^11.0.1" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /radlab-ui/webapp/setup-tests.ts: -------------------------------------------------------------------------------- 1 | import dotenv from 'dotenv' 2 | 3 | // Environment variables 4 | dotenv.config({ 5 | path: '.env.local', 6 | }) 7 | 8 | // Mocks 9 | jest.mock('next/router', () => require('next-router-mock')) 10 | jest.mock('react-i18next', () => ({ 11 | // this mock makes sure any components using the translate hook can use it without a warning being shown 12 | useTranslation: () => ({ 13 | t: (str: string): string => str, 14 | }), 15 | })) 16 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/routes/SignOut.tsx: -------------------------------------------------------------------------------- 1 | import { useRouter } from "next/router" 2 | import { auth } from "@/utils/firebase" 3 | import { userStore } from "@/store" 4 | 5 | const Signout = () => { 6 | const router = useRouter() 7 | const setUser = userStore((state) => state.setUser) 8 | 9 | if (process.browser) { 10 | auth.signOut() 11 | router.push("/signin") 12 | setTimeout(() => setUser(null)) 13 | } 14 | return <> 15 | } 16 | 17 | export default Signout 18 | -------------------------------------------------------------------------------- /radlab-ui/webapp/__mocks__/deployments.ts: -------------------------------------------------------------------------------- 1 | import { DEPLOYMENT_STATUS } from "@/utils/types" 2 | 3 | export const deploymentMockData = { 4 | id: "", 5 | createdAt: { _seconds: 1664378694, _nanoseconds: 972000000 }, 6 | variables: {}, 7 | status: DEPLOYMENT_STATUS.QUEUED, 8 | updatedAt: { _seconds: 1664378694, _nanoseconds: 973000000 }, 9 | projectId: "radlab-data-science-32fa", 10 | deployedByEmail: "", 11 | module: "", 12 | builds: [], 13 | deploymentId: "", 14 | } 15 | -------------------------------------------------------------------------------- /docs/src/pages/index.module.css: -------------------------------------------------------------------------------- 1 | /** 2 | * CSS files with the .module.css suffix will be treated as CSS modules 3 | * and scoped locally. 4 | */ 5 | 6 | .heroBanner { 7 | padding: 4rem 0; 8 | text-align: center; 9 | position: relative; 10 | overflow: hidden; 11 | } 12 | 13 | @media screen and (max-width: 996px) { 14 | .heroBanner { 15 | padding: 2rem; 16 | } 17 | } 18 | 19 | .buttons { 20 | display: flex; 21 | align-items: center; 22 | justify-content: center; 23 | } 24 | -------------------------------------------------------------------------------- /radlab-ui/webapp/public/locales/en/signin.json: -------------------------------------------------------------------------------- 1 | { 2 | "signin-title": "Sign In", 3 | "signin-description": "Sign in to get started", 4 | "signin-google": "Sign in with Google", 5 | "signin-password": "Sign in with email and password", 6 | "signin": "Sign in", 7 | "email": "Email", 8 | "password": "Password", 9 | 10 | "reset-password": "Reset your password", 11 | "reset": "Reset", 12 | "reset-email-sent": "A password reset email has been sent!", 13 | "back-to-signin": "Back to signin page" 14 | } 15 | -------------------------------------------------------------------------------- /modules/secure_data_warehouse/scripts/build/wrapped-key/requirements.txt: -------------------------------------------------------------------------------- 1 | cachetools==4.2.4 2 | certifi==2021.10.8 3 | charset-normalizer==2.0.7 4 | crcmod==1.7 5 | google-api-core==2.2.2 6 | google-auth==2.3.3 7 | google-cloud-kms==2.10.1 8 | googleapis-common-protos==1.53.0 9 | grpc-google-iam-v1==0.12.3 10 | grpcio==1.42.0 11 | grpcio-status==1.42.0 12 | idna==3.3 13 | proto-plus==1.19.8 14 | protobuf==3.19.1 15 | pyasn1==0.4.8 16 | pyasn1-modules==0.2.8 17 | requests==2.26.0 18 | rsa==4.8 19 | six==1.16.0 20 | urllib3==1.26.7 -------------------------------------------------------------------------------- /radlab-ui/webapp/src/routes/NotFound.tsx: -------------------------------------------------------------------------------- 1 | import { useTranslation } from "next-i18next" 2 | 3 | interface NotFoundProps {} 4 | 5 | const NotFound: React.FC = ({}) => { 6 | const { t } = useTranslation() 7 | 8 | return ( 9 |
10 |
404
11 |
{t("not-found")}
12 |
13 | ) 14 | } 15 | 16 | export default NotFound 17 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/ui_installation/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Installation", 3 | "position": 2, 4 | "link": { 5 | "slug": "ui_installation", 6 | "type": "generated-index", 7 | "description": "Cloud Admins can set up a privately hosted version of RAD Lab UI for their organization to use. The application is highly configurable with regards to what modules they want to publish to their users. Users can then use this application to spin up Google Cloud projects within the bounds set by the Cloud Admins." 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/store/alert.ts: -------------------------------------------------------------------------------- 1 | import { create } from "zustand" 2 | import { IAlert } from "@/utils/types" 3 | 4 | interface IAlertState { 5 | alert: null | IAlert 6 | setAlert: (alert: null | IAlert) => void 7 | } 8 | 9 | const useStore = create((set) => ({ 10 | alert: null, 11 | setAlert: (alert) => { 12 | if (alert?.durationMs) { 13 | setTimeout(() => { 14 | set({ alert: null }) 15 | }, alert.durationMs) 16 | } 17 | return set({ alert }) 18 | }, 19 | })) 20 | 21 | export default useStore -------------------------------------------------------------------------------- /radlab-ui/webapp/src/components/SectionHeader.tsx: -------------------------------------------------------------------------------- 1 | interface SectionHeaderProps { 2 | title: string 3 | } 4 | 5 | const SectionHeader: React.FC = ({ title }) => { 6 | return ( 7 |
11 | 12 | {title} 13 | 14 |
15 | ) 16 | } 17 | 18 | export default SectionHeader 19 | -------------------------------------------------------------------------------- /docs/docs/getting-started.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 1 3 | --- 4 | 5 | # Getting Started 6 | 7 | [RAD Lab](https://github.com/GoogleCloudPlatform/rad-lab/) enables quick deployments to Google Cloud Platform for common workloads. This helps developers, researchers, and other professionals quickly spin up cloud resources and start being productive. 8 | 9 | There are **3 ways to deploy RAD Lab modules** 10 | 1. [Terraform CLI](../category/terraform-cli/) 11 | 2. [RAD Lab Launcher](../category/rad-lab-launcher/) 12 | 3. [Webapp (RAD Lab UI)](../category/rad-lab-ui/) 13 | -------------------------------------------------------------------------------- /modules/web_hosting/scripts/build/startup_scripts/sample_app/templates/delete.html: -------------------------------------------------------------------------------- 1 | {% extends 'base.html' %} 2 | 3 | {% block content %} 4 |

{% block title %} Delete an Existing User {% endblock %}

5 |
6 | 7 |
8 | 11 |

12 | 13 | 14 |
15 | {% endblock %} -------------------------------------------------------------------------------- /radlab-ui/webapp/src/store/user.ts: -------------------------------------------------------------------------------- 1 | // https://github.com/pmndrs/zusta 2 | import { create } from "zustand" 3 | 4 | import { User } from "firebase/auth" 5 | 6 | interface IUserState { 7 | user: null | User 8 | isAdmin: boolean | null 9 | setUser: (user: null | User) => void 10 | setIsAdmin: (isAdmin: null | boolean) => void 11 | } 12 | 13 | const useStore = create((set) => ({ 14 | user: null, 15 | isAdmin: null, 16 | setUser: (user) => set({ user }), 17 | setIsAdmin: (isAdmin) => set({ isAdmin }), 18 | })) 19 | 20 | export default useStore -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/infrastructure/function/create_deployment/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "create_deployment", 3 | "version": "1.0.0", 4 | "description": "Create a RAD Lab module deployment", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "npm -- run unit-test" 8 | }, 9 | "author": "", 10 | "license": "Apache-2.0", 11 | "dependencies": { 12 | "@google-cloud/cloudbuild": "^3.1.0", 13 | "@google-cloud/functions-framework": "^3.1.2", 14 | "@google-cloud/storage": "^6.2.3", 15 | "firebase-admin": "^11.0.1" 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/components/LoadingRow.tsx: -------------------------------------------------------------------------------- 1 | import Loading from "@/navigation/Loading" 2 | 3 | interface LoadingRowProps { 4 | title: string 5 | } 6 | 7 | const LoadingRow: React.FC = ({ title }) => { 8 | return ( 9 |
13 | 14 |

15 | {title} 16 |

17 |
18 | ) 19 | } 20 | 21 | export default LoadingRow 22 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/pages/api/user.ts: -------------------------------------------------------------------------------- 1 | import { withAuth } from "@/utils/middleware" 2 | import { AuthedNextApiHandler } from "@/utils/types" 3 | import { NextApiResponse } from "next" 4 | 5 | const handler = async (req: AuthedNextApiHandler, res: NextApiResponse) => { 6 | const { email } = req.query 7 | 8 | if (req.method === "GET" && email) { 9 | if (!email) { 10 | return res.status(400).json({ message: "Please provide valid email" }) 11 | } 12 | 13 | return res.status(200).json(req.user) 14 | } 15 | } 16 | 17 | export default withAuth(handler) 18 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/ui_installation/cleanup.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: 06 - Cleanup Environment 3 | sidebar_position: 6 4 | --- 5 | 6 | The RAD Lab UI project can be deleted by executing the following steps in the `radlab-ui/automation/terraform/infrastructure` folder. 7 | 8 | 1. Delete the `backend.tf` file. 9 | 2. Run `terraform init -migrate-state`. This will copy the remote state to your local environment. 10 | 3. Run `terraform destroy -auto-approve`. This will delete the RAD Lab UI project and all the IAM permissions that were created as part of the installation. 11 | 12 | 13 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/styles/themes.js: -------------------------------------------------------------------------------- 1 | // Limit these to limit CSS size 2 | module.exports = [ 3 | "light", 4 | "dark", 5 | // "synthwave", 6 | // "dracula", 7 | // "fantasy", 8 | // "autumn", 9 | // "cupcake", 10 | // "bumblebee", 11 | // "emerald", 12 | // "corporate", 13 | // "retro", 14 | // "cyberpunk", 15 | // "valentine", 16 | // "halloween", 17 | // "garden", 18 | // "forest", 19 | // "aqua", 20 | // "lofi", 21 | // "pastel", 22 | // "wireframe", 23 | // "black", 24 | // "luxury", 25 | // "cmyk", 26 | // "business", 27 | // "acid", 28 | // "lemonade" 29 | ] 30 | -------------------------------------------------------------------------------- /radlab-ui/webapp/.gcloudignore: -------------------------------------------------------------------------------- 1 | # This file specifies files that are *not* uploaded to Google Cloud 2 | # using gcloud. It follows the same syntax as .gitignore, with the addition of 3 | # "#!include" directives (which insert the entries of the given .gitignore-style 4 | # file at that point). 5 | # 6 | # For more information, run: 7 | # $ gcloud topic gcloudignore 8 | # 9 | .gcloudignore 10 | # If you would like to upload your .git directory, .gitignore file or files 11 | # from your .gitignore file, remove the corresponding line 12 | # below: 13 | .git 14 | .gitignore 15 | 16 | # Node.js dependencies: 17 | node_modules/ -------------------------------------------------------------------------------- /radlab-ui/webapp/public/locales/es/signin.json: -------------------------------------------------------------------------------- 1 | { 2 | "signin-title": "Registrarse", 3 | "signin-description": "Inicia sesión para empezar", 4 | "signin-google": "Inicia sesión con Google", 5 | "signin-password": "Iniciar sesión con correo electrónico y contraseña", 6 | "signin": "Registrarse", 7 | "email": "Correo electrónico", 8 | "password": "Clave", 9 | 10 | "reset-password": "Restablecer su contraseña", 11 | "reset": "Reiniciar", 12 | "reset-email-sent": "¡Se ha enviado un correo electrónico de restablecimiento de contraseña!", 13 | "back-to-signin": "Volver a la página de inicio de sesión" 14 | } 15 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/utils/env.ts: -------------------------------------------------------------------------------- 1 | export const envOrFail = ( 2 | name: string, 3 | value: string | undefined, 4 | fallback?: string, 5 | ): string => { 6 | // Must explicitly pass in process.env.VAR_NAME otherwise NextJS won't load it 7 | // Can't do dynamic variables like: process.env[name] 8 | // https://nextjs.org/docs/basic-features/environment-variables 9 | if (typeof value === "undefined" || value === "") { 10 | if (fallback) { 11 | console.warn(`${name} was not set. Defaulting to ${fallback}`) 12 | return fallback 13 | } 14 | throw new Error(`${name} is not set`) 15 | } 16 | return value 17 | } 18 | -------------------------------------------------------------------------------- /radlab-ui/webapp/firebase.json: -------------------------------------------------------------------------------- 1 | { 2 | "firestore": { 3 | "rules": "firestore.rules", 4 | "indexes": "firestore.indexes.json" 5 | }, 6 | "storage": { 7 | "rules": "storage.rules" 8 | }, 9 | "emulators": { 10 | "auth": { 11 | "port": 9099 12 | }, 13 | "functions": { 14 | "port": 5001 15 | }, 16 | "firestore": { 17 | "port": 8080 18 | }, 19 | "hosting": { 20 | "port": 5000 21 | }, 22 | "pubsub": { 23 | "port": 8085 24 | }, 25 | "storage": { 26 | "port": 9199 27 | }, 28 | "ui": { 29 | "enabled": true, 30 | "port": 8090 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /radlab-ui/webapp/__tests__/utils/env.test.ts: -------------------------------------------------------------------------------- 1 | import { envOrFail } from "@/utils/env" 2 | 3 | describe("env util", () => { 4 | it("succeeds when env var is set", () => { 5 | const GCP_PROJECT_ID = envOrFail( 6 | "NEXT_PUBLIC_GCP_PROJECT_ID", 7 | process.env.NEXT_PUBLIC_GCP_PROJECT_ID, 8 | ) 9 | expect(GCP_PROJECT_ID).not.toBeNull() 10 | expect(GCP_PROJECT_ID).not.toEqual("") 11 | }) 12 | 13 | it("fails when env var is not set", () => { 14 | const missingEnvVar = () => { 15 | envOrFail("DOES_NOT_EXIST", process.env.DOES_NOT_EXIST) 16 | } 17 | expect(missingEnvVar).toThrow(Error("DOES_NOT_EXIST is not set")) 18 | }) 19 | }) 20 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/templates/Unauthenticated.tsx: -------------------------------------------------------------------------------- 1 | import { ReactNode, useEffect } from "react" 2 | 3 | type IUnauthenticatedProps = { 4 | meta: ReactNode 5 | children: ReactNode 6 | } 7 | 8 | const Unauthenticated = (props: IUnauthenticatedProps) => { 9 | // NextJS doesn't allow editing this field with className 10 | useEffect(() => { 11 | document.querySelector("#__next")?.classList.add("h-full") 12 | }) 13 | 14 | return ( 15 |
16 | {props.meta} 17 | 18 |
{props.children}
19 |
20 | ) 21 | } 22 | export default Unauthenticated 23 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/components/modules/ModuleOverviewCard.tsx: -------------------------------------------------------------------------------- 1 | import { IModuleCard } from "@/utils/types" 2 | 3 | interface ModuleOverviewCardProps { 4 | card: IModuleCard 5 | } 6 | 7 | const ModuleOverviewCard: React.FC = ({ card }) => { 8 | return ( 9 |
10 |
11 |

{card.title}

12 |

{card.body}

13 |
14 |
15 | ) 16 | } 17 | 18 | export default ModuleOverviewCard 19 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/ui_deployment/update-a-module.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 2 3 | --- 4 | 5 | # Updating a Module 6 | 7 | There are times you may want to update a module. Perhaps you... 8 | - provided a bad config value on the initial deployment 9 | - want to scale up or down certain resources 10 | - have other reasons 11 | 12 | 13 | 14 | Select a deployment from within RAD Lab UI. Then select the Update button. Provide new values and submit a new build. 15 | 16 | Behind the scenes were are calling `terraform apply` with the newly provided config values. Terraform will ensure these changes are reflected in your project. 17 | 18 | -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/modules/tf-builder/outputs.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | -------------------------------------------------------------------------------- /radlab-ui/webapp/public/assets/htmlTemplates/deleteEmail.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 |

Hello!

7 |

8 | RAD Lab Module with deployment ID - 9 | 10 | {{deploymentId}} 12 | has been successfully deleted! 13 |

14 | 15 |
16 |

Thank you

17 | 21 |

P.S:- This is an auto generated email. Please do not reply!

22 | 23 | 24 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/pages/ThemeChanger.tsx: -------------------------------------------------------------------------------- 1 | import { useEffect } from "react" 2 | import startCase from "lodash/startCase" 3 | import { themeChange } from "theme-change" 4 | interface ThemeChangerProps { 5 | themes: string[] 6 | } 7 | 8 | const ThemeChanger: React.FC = ({ themes }) => { 9 | useEffect(() => { 10 | themeChange(false) 11 | // 👆 false parameter is required for react project 12 | }, []) 13 | 14 | return ( 15 | 22 | ) 23 | } 24 | 25 | export default ThemeChanger 26 | -------------------------------------------------------------------------------- /docs/docs/rad-lab-ui/ui_deployment/delete-a-module.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 3 3 | --- 4 | 5 | # Delete a Module 6 | 7 | You may want to delete a module. Perhaps you... 8 | - deployed incorrectly 9 | - have finished the work intended for the module 10 | - are looking to tear down Google Cloud resources to save costs 11 | 12 | 13 | Select a deployment from within RAD Lab UI. Then select the Delete button. Confirm that you would like to delete. 14 | 15 | Behind the scenes were are calling `terraform destroy` to decomission the Google Cloud resources in the project. 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/components/NewDeploymentButton.tsx: -------------------------------------------------------------------------------- 1 | import { FolderAddIcon } from "@heroicons/react/outline" 2 | import { useNavigate } from "react-router-dom" 3 | 4 | interface NewDeploymentButtonProps { 5 | text: string 6 | } 7 | 8 | const NewDeploymentButton: React.FC = ({ text }) => { 9 | const navigate = useNavigate() 10 | 11 | return ( 12 | 20 | ) 21 | } 22 | 23 | export default NewDeploymentButton 24 | -------------------------------------------------------------------------------- /modules/genomics_dsub/scripts/build/container/fastqc-0.11.9a/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:20.04 2 | 3 | RUN apt-get update && apt-get install -y software-properties-common 4 | 5 | RUN apt-get update && \ 6 | apt-get install -y openjdk-8-jre && \ 7 | rm -rf /var/lib/apt/lists/* 8 | 9 | ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64/ 10 | 11 | RUN apt-get -qq update && apt-get -y upgrade && \ 12 | apt install -y wget libfindbin-libs-perl software-properties-common unzip 13 | 14 | RUN wget https://www.bioinformatics.babraham.ac.uk/projects/fastqc/fastqc_v0.11.9.zip -O /tmp/fastqc.zip && \ 15 | unzip /tmp/fastqc.zip -d /opt/ && \ 16 | rm /tmp/fastqc.zip && \ 17 | chmod 777 /opt/FastQC/fastqc 18 | 19 | ENV PATH="/opt/FastQC/:${PATH}" 20 | 21 | ENTRYPOINT ["fastqc"] 22 | -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/modules/tf-builder/entrypoint.bash: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Copyright 2023 Google LLC 4 | # 5 | # Licensed under the Apache License, Version 2.0 (the "License"); 6 | # you may not use this file except in compliance with the License. 7 | # You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, software 12 | # distributed under the License is distributed on an "AS IS" BASIS, 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | # See the License for the specific language governing permissions and 15 | # limitations under the License. 16 | 17 | echo "Running terraform $@ ..." 18 | 19 | terraform "$@" 20 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/pages/index.tsx: -------------------------------------------------------------------------------- 1 | import { serverSideTranslations } from "next-i18next/serverSideTranslations" 2 | import { useTranslation } from "next-i18next" 3 | 4 | import { Meta } from "@/layout/Meta" 5 | import { Main } from "@/templates/Main" 6 | 7 | const Index = () => { 8 | const { t: tc } = useTranslation("common") 9 | 10 | return ( 11 |
15 | } 16 | >
17 | ) 18 | } 19 | 20 | export default Index 21 | 22 | export async function getServerSideProps({ locale }: { locale: string }) { 23 | return { 24 | props: { 25 | ...(await serverSideTranslations(locale, ["common", "home"])), 26 | }, 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/components/AdminSettingsButton.tsx: -------------------------------------------------------------------------------- 1 | import { useNavigate } from "react-router-dom" 2 | import { CogIcon } from "@heroicons/react/outline" 3 | 4 | interface AdminSettingsButtonProps { 5 | text: string 6 | } 7 | 8 | const AdminSettingsButton: React.FC = ({ text }) => { 9 | const navigate = useNavigate() 10 | 11 | return ( 12 | 21 | ) 22 | } 23 | 24 | export default AdminSettingsButton 25 | -------------------------------------------------------------------------------- /radlab-ui/webapp/__mocks__/default.ts: -------------------------------------------------------------------------------- 1 | export const DEFAULT_ADMIN_VARS = ` 2 | 3 | variable "billing_id" { 4 | description = "Billing ID associated to the GCP Resources {{UIMeta group=1 order=1 }}" 5 | type = string 6 | } 7 | 8 | variable "organization_id" { 9 | description = "Organization ID where GCP Resources need to get spin up. It can be skipped if already setting folder_id {{UIMeta group=2 order=1 }}" 10 | type = string 11 | default = "" 12 | } 13 | 14 | variable "folder_id" { 15 | description = "Folder ID where the project should be created. It can be skipped if already setting organization_id. Leave blank if the project should be created directly underneath the Organization node. {{UIMeta group=3 order=1 }}" 16 | type = string 17 | default = "" 18 | }` 19 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/ask-for-help.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Ask for help 3 | about: Ask the community for help 4 | title: '' 5 | labels: question 6 | assignees: '' 7 | 8 | --- 9 | 10 | **What are you trying to accomplish?** 11 | Are you trying to deploy the platform for the first time? 12 | Is this about operating a deployed platform? 13 | Tell us a bit about what is going on. 14 | 15 | **What challenge are you running into?** 16 | Are you receiving an error or are things just not working as expected? 17 | What specifically is the problem? 18 | 19 | **What have your tried so far?** 20 | Include any relevant code snippets or logs that might help us understand. 21 | Make sure to remove any identifying information. 22 | 23 | **Labels** 24 | Please add labels that indicate which component(s) this request is related to. 25 | -------------------------------------------------------------------------------- /radlab-ui/webapp/__tests__/components/routeContainer.test.tsx: -------------------------------------------------------------------------------- 1 | import { render, screen } from "@testing-library/react" 2 | 3 | import RouteContainer from "@/components/RouteContainer" 4 | 5 | const CHILD_TEST_ID = "child-of-route-container" 6 | 7 | const TestComponent = () => { 8 | return
9 | } 10 | 11 | describe("RouteContainer", () => { 12 | it("should render child component", async () => { 13 | render( 14 | 15 | 16 | , 17 | ) 18 | 19 | const containerElement = screen.getByTestId("route-container") 20 | expect(containerElement).not.toEqual(null) 21 | 22 | const childElement = screen.getByTestId(CHILD_TEST_ID) 23 | expect(childElement).not.toEqual(null) 24 | }) 25 | }) 26 | -------------------------------------------------------------------------------- /modules/secure_data_warehouse/templates/schema_template.tpl: -------------------------------------------------------------------------------- 1 | [%{ for key, value in fields } 2 | { 3 | "name": "${key}", 4 | "mode": "${value.mode}", 5 | "type": "${value.type}"%{ for k, v in confidential_tags }%{ if "${key}"=="${k}" }, 6 | "policyTags": { 7 | "names": [ 8 | "${lookup("${pt_confidential}", "${key}")}" 9 | ] 10 | }%{ endif }%{ endfor }%{ for k, v in private_tags }%{ if "${key}"=="${k}" }, 11 | "policyTags": { 12 | "names": [ 13 | "${lookup("${pt_private}", "${key}")}" 14 | ] 15 | }%{ endif }%{ endfor }%{ for k, v in sensitive_tags }%{ if "${key}"=="${k}" }, 16 | "policyTags": { 17 | "names": [ 18 | "${lookup("${pt_sensitive}", "${key}")}" 19 | ] 20 | }%{ endif }%{ endfor } 21 | }%{ if "${index(keys(fields), key)}"<"${length(fields)}"-1 },%{ endif }%{ endfor } 22 | ] -------------------------------------------------------------------------------- /modules/NEON/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/alpha_fold/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/gen_ai/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/silicon/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /radlab-ui/webapp/__tests__/routes/admin.test.tsx: -------------------------------------------------------------------------------- 1 | import Admin from "@/routes/Admin" 2 | import { render, screen, waitFor } from "@testing-library/react" 3 | import "@testing-library/jest-dom" 4 | import { BrowserRouter } from "react-router-dom" 5 | 6 | //tests for image and button 7 | describe("admin component", () => { 8 | beforeEach(() => { 9 | render( 10 | 11 | 12 | , 13 | ) 14 | }) 15 | it.skip("should render the admin settings buutton", () => { 16 | waitFor(() => { 17 | const cancel_button = screen.getByTestId("cancel-button") 18 | expect(cancel_button).toBeInTheDocument() 19 | expect(cancel_button).toBeEnabled() 20 | const arrow = screen.getByTestId("arrow") 21 | expect(arrow).toBeInTheDocument() 22 | }) 23 | }) 24 | }) 25 | -------------------------------------------------------------------------------- /modules/app_mod_elastic/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/billing_budget/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/data_science/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/genomics_dsub/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /modules/web_hosting/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /radlab-ui/webapp/__tests__/components/sectionheader.test.tsx: -------------------------------------------------------------------------------- 1 | import { render, screen } from "@testing-library/react" 2 | import "@testing-library/jest-dom" 3 | import SectionHeader from "@/components/SectionHeader" 4 | import { useTranslation } from "next-i18next" 5 | 6 | describe("Section Header", () => { 7 | it("should render the section title", () => { 8 | const { t } = useTranslation() 9 | const title = t("global-vars") || t("deploy-module") || t("select-module") 10 | 11 | render() 12 | 13 | const titleElement = screen.getByTestId("section") 14 | expect(titleElement).not.toEqual(null) 15 | 16 | const titleElementName = screen.getByTestId("section-title") 17 | expect(titleElementName).not.toEqual(null) 18 | expect(titleElementName.innerHTML).toEqual(title) 19 | }) 20 | }) 21 | -------------------------------------------------------------------------------- /docs/docs/terraform-cli/cli_configure/customizing-modules.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 1 3 | --- 4 | 5 | # Customizing Modules 6 | 7 | After you have [cloned the the official RAD Lab repository](../../cli_installation/source-control), you can customize every module's defaults to match your organization's needs. 8 | 9 | ## Overriding default variables of a RAD Lab Module 10 | 11 | * Step down in the directory that contains the module specific Terraform code 12 | 13 | ```bash 14 | cd modules/[MODULE_NAME] 15 | ``` 16 | * Create a `terraform.tfvars` file. Below are the bare minimum require variables; feel free to override any other variables where you see fit. 17 | 18 | ```bash 19 | cat < terraform.tfvars 20 | billing_account_id = "ABCD-ABCD-ABCD" 21 | organization_id = "12345678901" 22 | folder_id = "98765432101" 23 | EOT 24 | ``` 25 | -------------------------------------------------------------------------------- /docs/docs/terraform-cli/cli_installation/source-control.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 1 3 | title: 01 - Source Control 4 | --- 5 | 6 | # Source Control 7 | 8 | ## Cloning official RAD Lab repository 9 | 10 | Check out the [RAD Lab GitHub repository](https://github.com/GoogleCloudPlatform/rad-lab/) directly into Google Cloud Shell by clicking the button below. 11 | 12 | :::tip 13 | You will need to follow [these steps](https://docs.github.com/en/github/authenticating-to-github/keeping-your-account-and-data-secure/creating-a-personal-access-token) to set up a GitHub Personal Access Token with **repo** scope. 14 | ::: 15 | 16 | [![Open in Cloud Shell](https://gstatic.com/cloudssh/images/open-btn.svg)](https://ssh.cloud.google.com/cloudshell/editor?cloudshell_git_repo=https://github.com/GoogleCloudPlatform/rad-lab&cloudshell_git_branch=main) 17 | 18 | -------------------------------------------------------------------------------- /modules/genomics_cromwell/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 4.0" 22 | google-beta = "~> 4.0" 23 | } 24 | } -------------------------------------------------------------------------------- /radlab-ui/webapp/__tests__/utils/validation.test.ts: -------------------------------------------------------------------------------- 1 | import { validators } from "@/utils/validation" 2 | 3 | const validationCheck = (variableName: string, value: string) => { 4 | const checks = validators[variableName] 5 | const validateStatus = checks?.every(({ fn }) => { 6 | const valid = fn(value) 7 | return valid 8 | }) 9 | return validateStatus 10 | } 11 | 12 | describe("validation util", () => { 13 | it("good project ID", () => { 14 | const project_id_prefix = validationCheck( 15 | "project_id_prefix", 16 | "projectname-project", 17 | ) 18 | expect(project_id_prefix).toBe(true) 19 | }) 20 | 21 | it("bad project ID", () => { 22 | const project_id_prefix = validationCheck( 23 | "project_id_prefix", 24 | "projectname-", 25 | ) 26 | expect(project_id_prefix).not.toBe(true) 27 | }) 28 | }) 29 | -------------------------------------------------------------------------------- /docs/sidebars.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Creating a sidebar enables you to: 3 | - create an ordered group of docs 4 | - render a sidebar for each doc of that group 5 | - provide next/previous navigation 6 | 7 | The sidebars can be generated from the filesystem, or explicitly defined here. 8 | 9 | Create as many sidebars as you want. 10 | */ 11 | 12 | // @ts-check 13 | 14 | /** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ 15 | const sidebars = { 16 | // By default, Docusaurus generates a sidebar from the docs folder structure 17 | tutorialSidebar: [{type: 'autogenerated', dirName: '.'}], 18 | 19 | // But you can create a sidebar manually 20 | /* 21 | tutorialSidebar: [ 22 | { 23 | type: 'category', 24 | label: 'Tutorial', 25 | items: ['hello'], 26 | }, 27 | ], 28 | */ 29 | }; 30 | 31 | module.exports = sidebars; 32 | -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/infrastructure/templates/backend.tf.tpl: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | backend "gcs" { 19 | bucket = "${TERRAFORM_STATE_BUCKET_NAME}" 20 | prefix = "${TERRAFORM_STATE_PREFIX}" 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /radlab-ui/automation/terraform/infrastructure/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = ">= 4.22.0" 22 | google-beta = ">= 4.22.0" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/utils/firebaseAdmin.ts: -------------------------------------------------------------------------------- 1 | import * as firebaseAdmin from "firebase-admin" 2 | import { envOrFail } from "@/utils/env" 3 | import { applicationDefault } from "firebase-admin/app" 4 | import { getFirestore } from "firebase-admin/firestore" 5 | 6 | const APP_NAME = "[DEFAULT]" 7 | 8 | const projectId = envOrFail( 9 | "NEXT_PUBLIC_FIREBASE_PROJECT_ID", 10 | process.env.NEXT_PUBLIC_FIREBASE_PROJECT_ID, 11 | ) 12 | 13 | const credential = applicationDefault() 14 | const config: firebaseAdmin.AppOptions = { 15 | credential, 16 | databaseURL: `https://${projectId}.firebaseio.com`, 17 | projectId, 18 | } 19 | 20 | const getApp = () => { 21 | return ( 22 | firebaseAdmin.apps.find((a) => a?.name === APP_NAME) || 23 | firebaseAdmin.initializeApp(config) 24 | ) 25 | } 26 | 27 | const db = getFirestore(getApp()) 28 | 29 | export { firebaseAdmin, getApp, db } 30 | -------------------------------------------------------------------------------- /modules/billing_budget/scripts/build/sample_startup_script.sh.tpl: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Copyright 2023 Google LLC 4 | # 5 | # Licensed under the Apache License, Version 2.0 (the "License"); 6 | # you may not use this file except in compliance with the License. 7 | # You may obtain a copy of the License at 8 | # 9 | # https://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, software 12 | # distributed under the License is distributed on an "AS IS" BASIS, 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | # See the License for the specific language governing permissions and 15 | # limitations under the License. 16 | 17 | sudo apt update && sudo apt -y install apache2 18 | 19 | sudo systemctl status apache2 20 | 21 | echo '

Hello World!

' | sudo tee /var/www/html/index.html -------------------------------------------------------------------------------- /radlab-ui/webapp/__mocks__/user.ts: -------------------------------------------------------------------------------- 1 | import { User } from 'firebase/auth' 2 | 3 | const user: User = { 4 | uid: '1', 5 | displayName: 'John Doe', 6 | email: 'jd@example.com', 7 | emailVerified: true, 8 | phoneNumber: '123456789', 9 | photoURL: 'https://lh3.googleusercontent.com/a-/AOh14GgeGwCRNIALP_N6QtZHVwZv-DFDorGkHNYNL8s=s96-c', 10 | tenantId: null, 11 | reload: () => Promise.resolve(), 12 | isAnonymous: false, 13 | metadata: {}, 14 | providerId: 'google', 15 | providerData: [], 16 | refreshToken: '', 17 | getIdToken: () => Promise.resolve(''), 18 | getIdTokenResult: () => Promise.resolve({ 19 | authTime: '', 20 | expirationTime: '', 21 | issuedAtTime: '', 22 | signInProvider: null, 23 | signInSecondFactor: null, 24 | token: '', 25 | claims: {}, 26 | }), 27 | delete: () => Promise.resolve(), 28 | toJSON: () => ({}), 29 | } 30 | 31 | export default user 32 | -------------------------------------------------------------------------------- /radlab-ui/webapp/src/pages/_document.tsx: -------------------------------------------------------------------------------- 1 | import Document, { Html, Head, Main, NextScript } from "next/document" 2 | import { AppConfig } from "@/utils/AppConfig" 3 | 4 | // Need to create a custom _document because i18n support is not compatible with `next export`. 5 | class MyDocument extends Document { 6 | render() { 7 | return ( 8 | 13 | 14 | 15 | {/* Adding so Tailwind doesn't purge these classes that we MAY use dynamically */} 16 | 17 | 18 |
19 | 20 | 21 | 22 | ) 23 | } 24 | } 25 | 26 | export default MyDocument 27 | -------------------------------------------------------------------------------- /modules/secure_data_warehouse/versions.tf: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright 2023 Google LLC 3 | * 4 | * Licensed under the Apache License, Version 2.0 (the "License"); 5 | * you may not use this file except in compliance with the License. 6 | * You may obtain a copy of the License at 7 | * 8 | * http://www.apache.org/licenses/LICENSE-2.0 9 | * 10 | * Unless required by applicable law or agreed to in writing, software 11 | * distributed under the License is distributed on an "AS IS" BASIS, 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | * See the License for the specific language governing permissions and 14 | * limitations under the License. 15 | */ 16 | 17 | terraform { 18 | required_version = "~> 1.0" 19 | 20 | required_providers { 21 | google = "~> 3.77" 22 | google-beta = "~> 3.77" 23 | 24 | local = { 25 | version = "~> 2.1" 26 | } 27 | } 28 | } -------------------------------------------------------------------------------- /radlab-ui/webapp/__tests__/navigation/footer.test.tsx: -------------------------------------------------------------------------------- 1 | import { INavigationItem } from "@/utils/types" 2 | import { render, screen } from "@testing-library/react" 3 | import Footer from "@/navigation/Footer" 4 | import { BrowserRouter } from "react-router-dom" 5 | 6 | describe("Footer", () => { 7 | it("contains links", () => { 8 | const routes: INavigationItem[] = [ 9 | { 10 | name: "Foo", 11 | href: "/foo", 12 | }, 13 | { 14 | name: "Bar", 15 | href: "/bar", 16 | }, 17 | { 18 | name: "Baz", 19 | href: "/baz", 20 | }, 21 | ] 22 | 23 | render( 24 | 25 |