diff --git a/website/.gitignore b/website/.gitignore new file mode 100644 index 0000000000..b2d6de3062 --- /dev/null +++ b/website/.gitignore @@ -0,0 +1,20 @@ +# Dependencies +/node_modules + +# Production +/build + +# Generated files +.docusaurus +.cache-loader + +# Misc +.DS_Store +.env.local +.env.development.local +.env.test.local +.env.production.local + +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/website/README.md b/website/README.md new file mode 100644 index 0000000000..ee0ccc9d18 --- /dev/null +++ b/website/README.md @@ -0,0 +1,33 @@ +# Website + +This website is built using [Docusaurus 2](https://v2.docusaurus.io/), a modern static website generator. + +### Installation + +``` +$ yarn +``` + +### Local Development + +``` +$ yarn start +``` + +This command starts a local development server and open up a browser window. Most changes are reflected live without having to restart the server. + +### Build + +``` +$ yarn build +``` + +This command generates static content into the `build` directory and can be served using any static contents hosting service. + +### Deployment + +``` +$ GIT_USER= USE_SSH=true yarn deploy +``` + +If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch. diff --git a/website/babel.config.js b/website/babel.config.js new file mode 100644 index 0000000000..e00595dae7 --- /dev/null +++ b/website/babel.config.js @@ -0,0 +1,3 @@ +module.exports = { + presets: [require.resolve('@docusaurus/core/lib/babel/preset')], +}; diff --git a/website/blog/2019-05-28-hola.md b/website/blog/2019-05-28-hola.md new file mode 100644 index 0000000000..5552da124f --- /dev/null +++ b/website/blog/2019-05-28-hola.md @@ -0,0 +1,11 @@ +--- +id: hola +title: Hola +author: Gao Wei +author_title: Docusaurus Core Team +author_url: https://github.com/wgao19 +author_image_url: https://avatars1.githubusercontent.com/u/2055384?v=4 +tags: [hola, docusaurus] +--- + +Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque elementum dignissim ultricies. Fusce rhoncus ipsum tempor eros aliquam consequat. Lorem ipsum dolor sit amet diff --git a/website/blog/2019-05-29-hello-world.md b/website/blog/2019-05-29-hello-world.md new file mode 100644 index 0000000000..3b33193938 --- /dev/null +++ b/website/blog/2019-05-29-hello-world.md @@ -0,0 +1,17 @@ +--- +id: hello-world +title: Hello +author: Endilie Yacop Sucipto +author_title: Maintainer of Docusaurus +author_url: https://github.com/endiliey +author_image_url: https://avatars1.githubusercontent.com/u/17883920?s=460&v=4 +tags: [hello, docusaurus] +--- + +Welcome to this blog. This blog is created with [**Docusaurus 2 alpha**](https://v2.docusaurus.io/). + + + +This is a test post. + +A whole bunch of other information. diff --git a/website/blog/2019-05-30-welcome.md b/website/blog/2019-05-30-welcome.md new file mode 100644 index 0000000000..3b5affedce --- /dev/null +++ b/website/blog/2019-05-30-welcome.md @@ -0,0 +1,13 @@ +--- +id: welcome +title: Welcome +author: Yangshun Tay +author_title: Front End Engineer @ Facebook +author_url: https://github.com/yangshun +author_image_url: https://avatars0.githubusercontent.com/u/1315101?s=400&v=4 +tags: [facebook, hello, docusaurus] +--- + +Blog features are powered by the blog plugin. Simply add files to the `blog` directory. It supports tags as well! + +Delete the whole directory if you don't want the blog features. As simple as that! diff --git a/docs/apiDefinition.json b/website/docs/apiDefinition.json similarity index 100% rename from docs/apiDefinition.json rename to website/docs/apiDefinition.json diff --git a/docs/cf-api-v2-usage.md b/website/docs/cf-api-v2-usage.md similarity index 100% rename from docs/cf-api-v2-usage.md rename to website/docs/cf-api-v2-usage.md diff --git a/docs/cf-api-v3.md b/website/docs/cf-api-v3.md similarity index 100% rename from docs/cf-api-v3.md rename to website/docs/cf-api-v3.md diff --git a/docs/cf-entity-scaling.md b/website/docs/cf-entity-scaling.md similarity index 100% rename from docs/cf-entity-scaling.md rename to website/docs/cf-entity-scaling.md diff --git a/docs/access.md b/website/docs/deploy/access.md similarity index 97% rename from docs/access.md rename to website/docs/deploy/access.md index e55688dc5c..81ffe6a171 100644 --- a/docs/access.md +++ b/website/docs/deploy/access.md @@ -1,4 +1,8 @@ -# Accessing Stratos +--- +id: access +title: Accessing Stratos +sidebar_label: Accessing Stratos +--- Depending on the deployment mode, you may require access to an UAA. Stratos also has the option to configure a local user account which removes the need for a UAA in non-Cloud Foundry deployments. diff --git a/deploy/all-in-one/README.md b/website/docs/deploy/all-in-one.md similarity index 97% rename from deploy/all-in-one/README.md rename to website/docs/deploy/all-in-one.md index a9d392934e..b886200088 100644 --- a/deploy/all-in-one/README.md +++ b/website/docs/deploy/all-in-one.md @@ -1,4 +1,8 @@ -# Deploying with the All-In-One Docker Container +--- +id: all-in-one +title: Deploying with the All-In-One Docker Container +sidebar_label: Deploy as Docker Container +--- The all-in-one container sets up the Stratos components in a single container. diff --git a/deploy/cloud-foundry/README.md b/website/docs/deploy/cloud-foundry.md similarity index 94% rename from deploy/cloud-foundry/README.md rename to website/docs/deploy/cloud-foundry.md index d06e09234e..c024ff244d 100644 --- a/deploy/cloud-foundry/README.md +++ b/website/docs/deploy/cloud-foundry.md @@ -1,4 +1,8 @@ -# Deploying as a Cloud Foundry Application +--- +id: cloud-foundry +title: Deploying as a Cloud Foundry Application +sidebar_label: Deploy on Cloud Foundry +--- ## Deployment Steps @@ -6,8 +10,8 @@ The quickest way to install Stratos is to deploy it as a Cloud Foundry applicati You can do it in two ways: -1. [Deploy Stratos from source](#Deploy-Stratos-from-source) -1. [Deploy Stratos from docker image](#Deploy-Stratos-from-docker-image) +1. [Deploy Stratos from source](#deploy-stratos-from-source) +1. [Deploy Stratos from docker image](#deploy-stratos-from-docker-image) You will then be able to open a web browser and navigate to the console URL: @@ -15,12 +19,12 @@ You will then be able to open a web browser and navigate to the console URL: Where `` is the default domain configured for your Cloud Foundry cluster. -To login use the following credentials detailed [here](../../docs/access.md). +To login use the following credentials detailed [here](access.md). If you run into issues, please refer to the [Troubleshooting Guide](#troubleshooting) below. > The console will pre-configure the host Cloud Foundry endpoint. No other CF instance should be registered unless the instructions in - the section [Associate Cloud Foundry database service](#Associate-Cloud-Foundry-database-service) are followed. + the section [Associate Cloud Foundry database service](#associate-cloud-foundry-database-service) are followed. All other deployment methods (helm, docker all-in-one, etc) allow the registration of multiple CF instances by default. Note: @@ -61,7 +65,7 @@ applications: This will set the the UAA client and UAA secret used to invite users for the default CF only. -See the [invite users guide](../../docs/invite-user-guide.md) for more information about user invites in Stratos. +See the [invite users guide](../guides/admin/invite-user-guide) for more information about user invites in Stratos. #### Use of the Default Embedded SQLite Database @@ -80,7 +84,7 @@ git checkout tags/stable -b stable cf push ``` -If the cf push exceeds the time allowed see the instructions [here](#Pre-building-the-UI) +If the cf push exceeds the time allowed see the instructions [here](#pre-building-the-ui) #### Pre-building the UI @@ -123,7 +127,7 @@ cf push console -o splatform/stratos:stable -m 128M -k 384M Alternatively cf push using a manifest -- download [manifest-docker.yml](../../manifest-docker.yml) or create your own manifest file: +- download [manifest-docker.yml](../../../manifest-docker.yml) or create your own manifest file: ```yaml applications: - name: console @@ -155,7 +159,7 @@ applications: When SSO Login is enabled, Stratos will also auto-connect to the Cloud Foundry it is deployed in using the token obtained during the SSO Login flow. -For more information - see [Single-Sign On](../../docs/sso.md). +For more information - see [Single-Sign On](../guides/admin/sso). ## Troubleshooting diff --git a/deploy/kubernetes/README.md b/website/docs/deploy/kubernetes.md similarity index 91% rename from deploy/kubernetes/README.md rename to website/docs/deploy/kubernetes.md index 6d8d583560..23b74f58f1 100644 --- a/deploy/kubernetes/README.md +++ b/website/docs/deploy/kubernetes.md @@ -1,4 +1,8 @@ -# Deploying in Kubernetes +--- +id: kubernetes +title: Deploying in Kubernetes +sidebar_label: Deploy on Kubernetes +--- Stratos can be deployed to Kubernetes using [Helm](https://github.com/kubernetes/helm). diff --git a/docs/invite-user-guide.md b/website/docs/guides/admin/invite-user-guide.md similarity index 98% rename from docs/invite-user-guide.md rename to website/docs/guides/admin/invite-user-guide.md index 58f9283f96..92aa2d7705 100644 --- a/docs/invite-user-guide.md +++ b/website/docs/guides/admin/invite-user-guide.md @@ -1,4 +1,8 @@ -# Invite User Guide +--- +id: invite-user-guide +title: Invite User Guide +sidebar_label: Invite Users +--- Stratos provides a way for Cloud Foundry administrators and organization managers to invite users to an organization or space. diff --git a/docs/sso.md b/website/docs/guides/admin/sso.md similarity index 95% rename from docs/sso.md rename to website/docs/guides/admin/sso.md index 8f9f747c67..f96f69b1f7 100644 --- a/docs/sso.md +++ b/website/docs/guides/admin/sso.md @@ -1,4 +1,8 @@ -# Single Sign On +--- +id: sso +title: Single Sign On +sidebar_label: Configure Single Sign On +--- By default, Stratos will authenticate against a UAA using username and password, for both logging into Stratos and when connecting Cloud Foundry endpoints. diff --git a/docs/contributing.md b/website/docs/guides/contribution/contributing.md similarity index 97% rename from docs/contributing.md rename to website/docs/guides/contribution/contributing.md index 2aeca4f947..0ecadf7a57 100644 --- a/docs/contributing.md +++ b/website/docs/guides/contribution/contributing.md @@ -1,4 +1,8 @@ -# Contributing to Stratos UI +--- +id: contributing +title: Contributing to Stratos UI +sidebar_label: Contributing to Stratos UI +--- ## Reporting issues diff --git a/docs/issue_template.md b/website/docs/guides/contribution/issue_template.md similarity index 77% rename from docs/issue_template.md rename to website/docs/guides/contribution/issue_template.md index dffaf1add3..b7db21a17a 100644 --- a/docs/issue_template.md +++ b/website/docs/guides/contribution/issue_template.md @@ -1,8 +1,10 @@ +--- +id: issue_template +title: Issue report template +sidebar_label: Issue report template +--- + -### Stratos Version - - - ### Frontend Deployment type @@ -25,11 +27,11 @@ ### Actual behaviour -### Steps to reproduce the behaviour +### Steps to reproduce the behavior ### Log output covering before error and any error statements ``` -Insert your log here +Insert log hereCopy ``` diff --git a/docs/pull_request_template.md b/website/docs/guides/contribution/pull_request_template.md similarity index 88% rename from docs/pull_request_template.md rename to website/docs/guides/contribution/pull_request_template.md index e651b7af6d..11568562b2 100644 --- a/docs/pull_request_template.md +++ b/website/docs/guides/contribution/pull_request_template.md @@ -1,3 +1,9 @@ +--- +id: pull_request_template +title: Pull request template for contributions to Stratos +sidebar_label: PR template +--- + ## Description diff --git a/docs/customizing.md b/website/docs/guides/customization/customizing.md similarity index 99% rename from docs/customizing.md rename to website/docs/guides/customization/customizing.md index e81f9ebabd..58780c1914 100644 --- a/docs/customizing.md +++ b/website/docs/guides/customization/customizing.md @@ -1,4 +1,8 @@ -# Customizing Stratos +--- +id: customizing +title: Customizing Stratos +sidebar_label: Customizing Stratos +--- Stratos provides a mechanism for customization - the following customizations are currently supported: diff --git a/docs/developers-guide-e2e-tests.md b/website/docs/guides/developers/developers-guide-e2e-tests.md similarity index 98% rename from docs/developers-guide-e2e-tests.md rename to website/docs/guides/developers/developers-guide-e2e-tests.md index dbac463428..4ae87a94de 100644 --- a/docs/developers-guide-e2e-tests.md +++ b/website/docs/guides/developers/developers-guide-e2e-tests.md @@ -1,4 +1,8 @@ -# E2E Tests +--- +id: developers-guide-e2e-tests +title: E2E Tests +sidebar_label: E2E Tests +--- The Stratos E2E test suite exercises the Stratos UI using protractor/web-driver. diff --git a/docs/developers-guide-env-tech.md b/website/docs/guides/developers/developers-guide-env-tech.md similarity index 97% rename from docs/developers-guide-env-tech.md rename to website/docs/guides/developers/developers-guide-env-tech.md index 7e22201b90..76918f9fba 100644 --- a/docs/developers-guide-env-tech.md +++ b/website/docs/guides/developers/developers-guide-env-tech.md @@ -1,4 +1,8 @@ -# Stratos Tech + Developer Environment +--- +id: developers-guide-env-tech +title: Stratos Tech + Developer Environment +sidebar_label: Dev Environment +--- ## ES6 diff --git a/docs/developers-guide.md b/website/docs/guides/developers/developers-guide.md similarity index 99% rename from docs/developers-guide.md rename to website/docs/guides/developers/developers-guide.md index 5491b1b705..f7163b1f20 100644 --- a/docs/developers-guide.md +++ b/website/docs/guides/developers/developers-guide.md @@ -1,5 +1,8 @@ - -# Developing the Stratos Console +--- +id: developers-guide +title: Developing the Stratos Console +sidebar_label: Stratos Development +--- 1. [Introduction](#introduction) 1. [Frontend Development](#frontend-development) diff --git a/docs/backend-plugins.md b/website/docs/guides/extensions/backend-plugins.md similarity index 98% rename from docs/backend-plugins.md rename to website/docs/guides/extensions/backend-plugins.md index 4aba144c68..33b64f8a05 100644 --- a/docs/backend-plugins.md +++ b/website/docs/guides/extensions/backend-plugins.md @@ -1,4 +1,8 @@ -# Backend Plugins +--- +id: backend-plugins +title: Backend Plugins +sidebar_label: Backend +--- This document provides a brief outline for extending the Stratos backend (Jetstream). diff --git a/docs/extensions.md b/website/docs/guides/extensions/frontend-extensions.md similarity index 84% rename from docs/extensions.md rename to website/docs/guides/extensions/frontend-extensions.md index 918c25df18..cf70417e58 100644 --- a/docs/extensions.md +++ b/website/docs/guides/extensions/frontend-extensions.md @@ -1,4 +1,8 @@ -# Front-end Extensions +--- +id: frontend-extensions +title: Front-end Extensions +sidebar_label: Frontend +--- An example illustrating the various front-end extension points of Stratos is included in the folder `examples/custom-src`. @@ -81,20 +85,7 @@ For example: The approach for all of these is the same: 1. Create a new component that will provide the tab contents -2. Ensure that your component is declared with the `ExtensionService` in the imports of your custom module, for example: -``` - @NgModule({ - imports: [ - ExtensionService.declare([ - ExtensionComponent, - ]) - ], - declarations: [ - ExtensionComponent - ] - }) -``` - +2. Ensure that your component is included in the `EntryComponent` section of your custom module 2. Decorate the component with the `StratosTab` decorator, for example: ``` @@ -107,13 +98,13 @@ The approach for all of these is the same: Where: -- indicates where the tab should appear and can be: +- < TYPE > indicates where the tab should appear and can be: - StratosTabType.Application - Application View - StratosTabType.CloudFoundry - Cloud Foundry view - StratosTabType.CloudFoundryOrg - Cloud Foundry Org view - StratosTabType.CloudFoundrySpace - Cloud Foundry Space view --