Commit 223ee5f9 authored by Sergio Gimenez's avatar Sergio Gimenez
Browse files

Keep docs very simple for now

parent ce7bee8b
Loading
Loading
Loading
Loading
+15 −0
Original line number Diff line number Diff line
@@ -48,9 +48,24 @@ port_mappings:
  - name: prometheus
    container_port: 30090
    host_port: 30090
  - name: grafana
    container_port: 30091
    host_port: 30091
  - name: alertmanager
    container_port: 30092
    host_port: 30092
  - name: harbor-http
    container_port: 30002
    host_port: 30002
  - name: harbor-https
    container_port: 30003
    host_port: 30003
  - name: i2edge-service
    container_port: 30769
    host_port: 30769
  - name: artefact-manager
    container_port: 30080
    host_port: 30080
```

### Override Variables

docs/quick-start.md

0 → 100644
+128 −0
Original line number Diff line number Diff line
# Quick Start Guide

## Prepare The Inventory

This quick start guide will guide you through the initial steps to deploy and manage the Operator Platform using the provided Ansible automation framework.

First is recommended to start with a clean VM running Ubuntu 24.04. Then, add the VM details to the inventory file and configure SSH access. So in the `inventory/hosts.yml` file, add your VM's IP address and SSH user credentials:

```yaml
all:
  hosts:
    your_vm_name:
      ansible_host: your_vm_ip
      ansible_user: your_ssh_user
      ansible_ssh_private_key_file: /path/to/your/private/key
```

Also, make sure the host `your_vm_name` is included in the appropriate group or children section:

```yaml
  children:
    kind_cluster:
      hosts:
        your_vm_name:
```

Then, you can proceed with running the Ansible playbooks to deploy and manage the Operator Platform on your VM.

## Install Dependencies

!!! note
    Make sure you are in the `ansible` directory. And virtual env is activated: 
    ```bash
    source venv/bin/activate
    ```

Now, let's install all the necessary dependencies on your VM by running the following playbook:

```bash
ansible-playbook playbooks/00-install-python-deps.yml
ansible-playbook playbooks/00-setup-docker.yml
ansible-playbook playbooks/00-setup-kubectl.yml
ansible-playbook playbooks/00-setup-python-libs.yml
```

!!! note
    You might need a sudo password to install deps.

Once dependencies are installed, then we can deploy the cluster.

## Deploy The Cluster

Now let's deploy the kind cluster with 3 nodes: 1 control plane and 2 workers.

!!! info
    This is the default configuration with 1 control plane and 2 worker nodes. You can customize the number of nodes in the `group_vars/all.yml` file by modifying the `worker_nodes` variable:

    ```yaml
    # Cluster nodes configuration
    control_plane_nodes: 1
    worker_nodes: 2
    ```
```bash
ansible-playbook playbooks/01-deploy-kind-cluster.yml
```

Once the cluster is deployed, you can access it from anywhere by using the generated kubeconfig:

```bash
venv) ➜  ansible git:(master)export KUBECONFIG=/path_to_project/OperatorPlatform/OP_Automation/automation/1-kind-cluster/operator-platform-external-kubeconfig.yaml

(venv) ➜  ansible git:(master) ✗ kubectl get nodes -o wide
NAME                              STATUS   ROLES           AGE   VERSION   INTERNAL-IP   EXTERNAL-IP   OS-IMAGE                         KERNEL-VERSION     CONTAINER-RUNTIME
operator-platform-control-plane   Ready    control-plane   90s   v1.33.1   172.18.0.2    <none>        Debian GNU/Linux 12 (bookworm)   6.8.0-49-generic   containerd://2.1.1
operator-platform-worker          Ready    <none>          79s   v1.33.1   172.18.0.4    <none>        Debian GNU/Linux 12 (bookworm)   6.8.0-49-generic   containerd://2.1.1
operator-platform-worker2         Ready    <none>          79s   v1.33.1   172.18.0.3    <none>        Debian GNU/Linux 12 (bookworm)   6.8.0-49-generic   containerd://2.1.1
```

## Deploy i2edge

To deploy i2edge we first need to install its dependencies in the cluster.

!!! info
    This playbook does not yet provides support for installing GPU drivers

```bash
ansible-playbook playbooks/02-install-i2edge-dependencies.yml
```

Then, install i2ede

!!! warning
    This is playbook does many workarounds to be able to deploy i2edge on the cluster such as rsync the code to the VM and build the image and then add it to the cluster. This is ugly and needs to be fixed, but works for now.


```bash
ansible-playbook playbooks/02-deploy-i2edge.yml
```

!!! success
    If everything went fine,  i2edge should be accessible directly in http://VM_IP:30769/docs

## Deploy Artifact Registry (Harbor)

We provide a playbook to deploy a Harbor instance to work as the artefact registry for the operator platform. To deploy Harbor run the following playbook:

```bash
ansible-playbook playbooks/02-deploy-harbor.yml
```

!!! success
    If everything went fine, harbor should be accessible directly in http://VM_IP:30002.

!!! info
    Default Harbor credentials are: `admin` / `Harbor12345`. However those can be changed before the playbook run  in the `ansible/roles/harbor/defaults/main.yml` file.

## Deploy Artefact Manager


To deploy the artefact manager:

```
ansible-playbook playbooks/03-deploy-artefact-manager.yml
```

!!! success
    If everything went fine, artefact manager API should be accessible directly in http://VM_IP:30080.
+7 −6
Original line number Diff line number Diff line
@@ -33,12 +33,13 @@ theme:

nav:
  - Home: index.md
  - Getting Started: getting-started.md
  - Architecture: architecture.md
  - Components:
    - Artefact Manager: artefact-manager.md
  - Playbooks: playbooks.md
  - Roles: roles.md
  - Getting Prepared: getting-started.md
  - Quick Start: quick-start.md
  # - Architecture: architecture.md
  # - Components:
  #   - Artefact Manager: artefact-manager.md
  # - Playbooks: playbooks.md
  # - Roles: roles.md
  - Troubleshooting: troubleshooting.md

markdown_extensions:
+1 −1

File changed.

Contains only whitespace changes.