Merge pull request #10512 from LvffY/master

[#10459] 📝 Update documentation to use yarn --cwd arg
This commit is contained in:
Johan Haals
2022-03-30 09:13:55 +02:00
committed by GitHub
14 changed files with 28 additions and 43 deletions
+2 -4
View File
@@ -19,8 +19,7 @@ package.
```bash
# From your Backstage root directory
cd packages/app
yarn add @backstage/plugin-kubernetes
yarn add --cwd packages/app @backstage/plugin-kubernetes
```
Once the package has been installed, you need to import the plugin in your app
@@ -50,8 +49,7 @@ Navigate to `packages/backend` of your Backstage app, and install the
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-kubernetes-backend
yarn add --cwd packages/backend @backstage/plugin-kubernetes-backend
```
Create a file called `kubernetes.ts` inside `packages/backend/src/plugins/` and
+2 -4
View File
@@ -18,8 +18,7 @@ If you haven't setup Backstage already, start
```bash
# From your Backstage root directory
cd packages/app
yarn add @backstage/plugin-search
yarn add --cwd packages/app @backstage/plugin-search
```
Create a new `packages/app/src/components/search/SearchPage.tsx` file in your
@@ -134,8 +133,7 @@ Add the following plugins into your backend app:
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-search-backend @backstage/plugin-search-backend-node
yarn add --cwd packages/backend @backstage/plugin-search-backend @backstage/plugin-search-backend-node
```
Create a `packages/backend/src/plugins/search.ts` file containing the following
+2 -4
View File
@@ -23,8 +23,7 @@ Navigate to your new Backstage application directory. And then to your
```bash
# From your Backstage root directory
cd packages/app
yarn add @backstage/plugin-techdocs
yarn add --cwd packages/app @backstage/plugin-techdocs
```
Once the package has been installed, you need to import the plugin in your app.
@@ -65,8 +64,7 @@ Navigate to `packages/backend` of your Backstage app, and install the
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-techdocs-backend
yarn add --cwd packages/backend @backstage/plugin-techdocs-backend
```
Create a file called `techdocs.ts` inside `packages/backend/src/plugins/` and
+2 -3
View File
@@ -65,10 +65,9 @@ to install and configure the client.
Stop Backstage, and go to the root directory of your freshly installed Backstage
App. Use the following commands to start the PostgreSQL client installation:
```shell
```bash
# From your Backstage root directory
cd packages/backend
yarn add pg
yarn add --cwd packages/backend pg
```
Use your favorite editor to open `app-config.yaml` and add your PostgreSQL
+3 -4
View File
@@ -28,10 +28,9 @@ Now, let's get started by installing the home plugin and creating a simple homep
#### 1. Install the plugin
```
# From your Backstage application directory
cd packages/app
yarn add @backstage/plugin-home
```bash
# From your Backstage root directory
yarn add --cwd packages/app @backstage/plugin-home
```
#### 2. Create a new HomePage component
@@ -67,8 +67,8 @@ terminal windows, both starting from the Backstage project root.
In the first window, run
```bash
cd packages/backend
yarn start
# From your Backstage root directory
yarn start --cwd packages/backend
```
That starts up a backend instance on port 7007.
+3 -3
View File
@@ -29,9 +29,9 @@ Note the `s3-discovery` type, as this is not a regular `url` processor.
As this processor is not one of the default providers, you will first need to install the AWS catalog plugin:
```shell
cd packages/backend
yarn install @backstage/plugin-catalog-backend-module-aws
```bash
# From the Backstage root directory
yarn install --cwd packages/backend @backstage/plugin-catalog-backend-module-aws
```
Once you've done that, you'll also need to add the segment below to `packages/backend/src/plugins/catalog.ts`:
+1 -2
View File
@@ -21,8 +21,7 @@ package.
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-catalog-backend-module-azure
yarn add --cwd packages/backend @backstage/plugin-catalog-backend-module-azure
```
And then add the processors to your catalog builder:
+1 -2
View File
@@ -20,8 +20,7 @@ package.
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-catalog-backend-module-bitbucket
yarn add --cwd packages/backend @backstage/plugin-catalog-backend-module-bitbucket
```
And then add the processor to your catalog builder:
+1 -2
View File
@@ -21,8 +21,7 @@ package.
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-catalog-backend-module-github
yarn add --cwd packages/backend @backstage/plugin-catalog-backend-module-github
```
And then add the processors to your catalog builder:
+1 -2
View File
@@ -22,8 +22,7 @@ to `@backstage/plugin-catalog-backend-module-ldap` to your backend package.
```bash
# From your Backstage root directory
cd packages/backend
yarn add @backstage/plugin-catalog-backend-module-ldap
yarn add --cwd packages/backend @backstage/plugin-catalog-backend-module-ldap
```
> Note: When configuring to use a Provider instead of a Processor you do not
+2 -3
View File
@@ -65,10 +65,9 @@ Backstage application / backend exposes it.
To actually attach and run the plugin router, you will make some modifications
to your backend.
```sh
```bash
# From the Backstage root directory
cd packages/backend
yarn add @internal/plugin-carmen-backend@^0.1.1 # Change this to match the plugin's package.json
yarn add --cwd packages/backend @internal/plugin-carmen-backend@^0.1.1 # Change this to match the plugin's package.json
```
Create a new file named `packages/backend/src/plugins/carmen.ts`, and add the
@@ -36,14 +36,13 @@ Please ensure the appropriate database drivers are installed in your `backend`
package. If you intend to use both PostgreSQL and SQLite, you can install
both of them.
```sh
cd packages/backend
```bash
# From the Backstage root directory
# install pg if you need PostgreSQL
yarn add pg
yarn add --cwd packages/backend pg
# install SQLite 3 if you intend to set it as the client
yarn add better-sqlite3
yarn add --cwd packages/backend better-sqlite3
```
From an operational perspective, you only need to install drivers for clients
+2 -3
View File
@@ -19,10 +19,9 @@ switch between database backends.
First, add PostgreSQL to your `backend` package:
```shell
```bash
# From your Backstage root directory
cd packages/backend
yarn add pg
yarn add --cwd packages/backend pg
```
## Add PostgreSQL configuration