Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(tutorials): batch one #4026

Merged
merged 2 commits into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions tutorials/deploy-hasura-engine-database-postgresql/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ categories:
- postgresql-and-mysql
hero: assets/scaleway_hasura.webp
dates:
validation: 2024-05-13
validation: 2024-11-25
posted: 2020-07-08
---

Expand All @@ -37,19 +37,19 @@ Hasura provides a pre-configured [repository](https://github.com/hasura/graphql-

2. Update the `docker-run.sh` script with your PostgreSQL database credentials:

Open the file in a text editor and locate the `HASURA_GRAPHQL_DATABASE_URL` environment variable. Replace `postgres://username:password@hostname:port/dbname` with your database credentials.
Open the file in a text editor and locate the `HASURA_GRAPHQL_DATABASE_URL` environment variable. Replace `postgres://username:password@hostname:port/dbname` with your database credentials. Choose a value for `youradminsecret` that you will use to log in to the Hasura console in the next section.

```bash
#! /bin/bash
docker run -d -p 8080:8080 \
-e HASURA_GRAPHQL_DATABASE_URL=postgres://youruser:yourpassword@yourhost:5432/yourdatabase \
-e HASURA_GRAPHQL_DATABASE_URL=postgres://youruser:yourpassword@yourhost:5432/dbname \
-e HASURA_GRAPHQL_ENABLE_CONSOLE=true \
-e HASURA_GRAPHQL_ADMIN_SECRET=youradminsecret \
hasura/graphql-engine:latest
```

<Message type="note">
If your database password contains special characters like `@` or `#`, ensure they are [URL-encoded](https://en.wikipedia.org/wiki/Percent-encoding#Percent-encoding_reserved_characters).
If your database password contains special characters like `@`, `!`, or `#`, ensure they are [URL-encoded](https://en.wikipedia.org/wiki/Percent-encoding#Percent-encoding_reserved_characters). The default `dbname` is `rdb`.
</Message>

3. Run the script:
Expand All @@ -67,7 +67,7 @@ Hasura provides a pre-configured [repository](https://github.com/hasura/graphql-
5. Access the Hasura Console by opening `http://localhost:8080/console` in your browser. You need to use the `HASURA_GRAPHQL_ADMIN_SECRET` value to log in.


### Setting Up Your First Tables and Queries
### Setting Up Your first tables and queries

1. Create tables in the Hasura Console:
- Click Data -> Create Table.
Expand Down
58 changes: 29 additions & 29 deletions tutorials/get-started-crossplane-kubernetes/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ tags: crossplane kubernetes
categories:
- kubernetes
dates:
validation: 2024-05-13
validation: 2024-11-25
posted: 2023-05-05
---

Expand All @@ -35,7 +35,7 @@ In this tutorial, you will learn how to install Upbound Universal Crossplane (UX
Run the following command to download and install the Upbound `up` command-line interface:

```bash
curl -sL "https://cli.upbound.io/stable/up" | sh
curl -sL "https://cli.upbound.io" | sh
sudo mv up /usr/local/bin/
```
<Message type="note">
Expand All @@ -53,7 +53,7 @@ Run the following `up uxp install` command to install the latest stable version
You should see an output like the following:

```plaintext
UXP 1.12.0 installed
UXP 1.18.0-up.1 installed
```

## Installing the provider into your Kubernetes cluster
Expand Down Expand Up @@ -101,7 +101,7 @@ Run the following `up uxp install` command to install the latest stable version

```
NAME INSTALLED HEALTHY PACKAGE AGE
provider-scaleway True True xpkg.upbound.io/scaleway/provider-scaleway:v0.1.0 11s
provider-scaleway True True xpkg.upbound.io/scaleway/provider-scaleway:v0..0 11s
```

<Message type="note">
Expand All @@ -116,13 +116,25 @@ Run the following `up uxp install` command to install the latest stable version

The provider requires credentials to create and manage Scaleway resources.

1. Run the following command to create a `secret.yaml` file in which your Kubernetes secret configuration will be stored:
1. Run the following command to create a `crossplane-system` [namespace](/containers/container-registry/concepts/#namespace):

```
kubectl create namespace crossplane-system --dry-run=client -o yaml | kubectl apply -f -
```

You should get an output similar to the following:

```
namespace/crossplane-system created
```

2. Run the following command to create a `secret.yaml` file in which your Kubernetes secret configuration will be stored:

```
nano secret.yaml
```

2. Edit the request payload you will use to create your Kubernetes secret configuration file. Replace the parameters in the following example using the information in the configuration reference table:
3. Edit the request payload you will use in the `secret.yaml` file, to create your Kubernetes secret. Replace the parameters in the following example using the information in the [configuration reference table](#configuration-reference-table-secret-resource):

```
apiVersion: v1
Expand All @@ -146,9 +158,9 @@ The provider requires credentials to create and manage Scaleway resources.
Secret names must be a valid DNS subdomain, meaning they must consist of lowercase alphanumeric characters, hyphens ("-") or periods and must start and end with an alphanumeric character. Underscores ("_") are not permitted.
</Message>

3. Paste the content of the request payload and save the changes by following the information displayed on your terminal.
4. Paste the content of the request payload into the contents of the `secret.yaml` file, and save the changes by following the information displayed on your terminal.

4. Run the following command to create the secret previously defined in the secret.yaml file.
5. Run the following command to create the secret you just defined in the `secret.yaml` file.

```
kubectl apply -f secret.yaml
Expand All @@ -160,18 +172,6 @@ The provider requires credentials to create and manage Scaleway resources.
secret/name-of-secret created
```

5. Run the following command to create a `crossplane-system` [namespace](/containers/container-registry/concepts/#namespace):

```
kubectl create namespace crossplane-system --dry-run=client -o yaml | kubectl apply -f -
```

You should get an output similar to the following:

```
namespace/crossplane-system created
```

6. Run the following command to retrieve details about your secret:

```
Expand All @@ -182,7 +182,7 @@ The provider requires credentials to create and manage Scaleway resources.
As the information is considered sensitive, the actual secret data will not be returned.
</Message>

### Configuration reference table
### Configuration reference table - secret resource

| Parameter | Description |
| :----------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
Expand All @@ -204,7 +204,7 @@ Create a `.yaml` configuration file to attach your Scaleway credentials to the p
nano providerconfig
```

2. Edit the request payload you will use to create your `providerconfig` file. Replace the parameters in the following example using the information in the configuration reference table:
2. Edit the request payload you will use to create your `providerconfig` file. Replace the parameters in the following example using the information in the [configuration reference table](#configuration-reference-table-providerconfig):

```
apiVersion: scaleway.upbound.io/v1beta1
Expand All @@ -213,14 +213,14 @@ Create a `.yaml` configuration file to attach your Scaleway credentials to the p
name: default
spec:
credentials:
source: Secret
secretRef:
name: name-of-secret
namespace: crossplane-system
key: credentials
source: Secret
secretRef:
name: name-of-secret
namespace: crossplane-system
key: credentials
```

3. Paste the content of the request payload and save the changes by following the information displayed on your terminal.
3. Paste the content of the request payload into the `providerconfig` file, and save the changes by following the information displayed on your terminal.

4. Run the following command to apply the previously set configuration to the secret. Make sure to replace the example file path with your own.

Expand Down Expand Up @@ -306,7 +306,7 @@ Create a `.yaml` configuration file to attach your Scaleway credentials to the p
Events: <none>
```

### Configuration reference table
### Configuration reference table - providerconfig

| Parameter | Description |
| :---------- | :----------------------------------------- |
Expand Down
9 changes: 3 additions & 6 deletions tutorials/upgrade-managed-postgresql-database/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,11 @@ content:
paragraph: This page shows how to upgrade your Database for PostgreSQL to the latest version
tags: storage PostgreSQL Database rdb
dates:
validation: 2024-05-20
validation: 2024-11-25
categories:
- postgresql-and-mysql
---

<Message type="important">
PostgreSQL version 10 reached its End of Life (EoL) on November 10, 2022. It is **recommended** to upgrade your PostgreSQL database engine to the latest available version as soon as possible.
</Message>


[PostgreSQL](https://www.postgresql.org/) is a powerful, open-source object-relational database system with more than 30 years of active development. As major PostgreSQL releases regularly add new features, the layout of the system tables may change. However, the internal data storage format itself rarely changes. This allows you to upgrade a PostgreSQL database system without data loss using the backup and restore functions of the Database API.

Expand Down Expand Up @@ -46,7 +43,7 @@ There are three steps to completing a manual migration: creating a new PostgreSQ
</Message>

1. Open the [Scaleway console](https://console.scaleway.com) in a web browser and click **Managed Databases** in the **Storage** section of the side menu. The list of your databases displays.
2. Click **+ Create an Instance**. The [Instance creation wizard](https://console.scaleway.com/rdb/instances/create) displays.
2. Click **+ Create a Database Instance**. The [Database Instance creation wizard](https://console.scaleway.com/rdb/instances/create) displays.
3. Select **PostgreSQL-13** from the drop-down list and fill in the [required information](/managed-databases/postgresql-and-mysql/how-to/create-a-database/) for your new database Instance. Then click **Create an Instance**. Your database is created, and you are redirected to the database dashboard.
<Message type="note">
Ensure your new Database Instance is located in the same geographical region as your old one.
Expand Down