|
1 | | -# Deploy using Docker |
2 | 1 |
|
3 | | -It is recommended to use Docker Compose for deploying the NetApp Connector (Neo) using Docker. Docker Compose simplifies the deployment process by allowing you to define and manage multi-container Docker applications with a single configuration file. |
| 2 | +# Deploy using Docker/Podman |
| 3 | + |
| 4 | +This guide provides the necessary steps to deploy a "battery-included" Neo instance, using Docker or Podman that includes: |
| 5 | + |
| 6 | +- an official PostgreSQL instance, version 16.10-alpine3.21 |
| 7 | +- version 3.1.1 of Neo |
| 8 | +- version 3.1.1 of Neo UI |
| 9 | + |
| 10 | +For testing purposes, a local SAMBA service is also included. |
4 | 11 |
|
5 | 12 | ## Prerequisites |
6 | 13 |
|
7 | | -Before deploying the NetApp Connector (Neo) using Docker Compose, ensure that you have the following prerequisites in place: |
| 14 | +Before deploying the NetApp Connector (Neo) using Podman Compose, ensure that you have the following prerequisites in place: |
8 | 15 |
|
9 | | -- Docker installed on your system. You can download Docker from the [official Docker website](https://www.docker.com/get-started). |
| 16 | +::: details Docker |
| 17 | +- Docker installed on your system. You can download Docker from the [official Docker website](https://www.docker.com/get-started/). |
10 | 18 | - Docker Compose installed. You can find installation instructions on the [Docker Compose installation page](https://docs.docker.com/compose/install/). |
11 | | -- Sufficient system resources to run the NetApp Connector (Neo). Refer to the [Sizing Guide](deployment#sizing-guide) in the Deployment section for recommended specifications. |
| 19 | +::: |
| 20 | + |
| 21 | +::: details Podman |
| 22 | +- Podman installed on your system. You can download Podman from the [official Podman website](https://podman.io/getting-started/installation). |
| 23 | +- Podman Compose installed. You can install it using the [Podman Compose installation instructions](https://github.com/containers/podman-compose). |
| 24 | +::: |
| 25 | + |
| 26 | +- Sufficient system resources to run the NetApp Core Connector. Refer to the [Sizing Guide](/projects/neo/core/d-sizing.md) in the Deployment section for recommended specifications. |
| 27 | +- ```cifs-utils``` package needs to be deployed on the Linux host. |
| 28 | +- ```SELinux``` contexts might require adjustements based on your specific Linux host security profile. |
| 29 | + |
| 30 | +> [!WARNING] |
| 31 | +> The main difference between ```docker``` and ```podman``` is linked to ```podman``` requiring a ```sudo``` prefix to start as a privileged container which is not required by ```docker``` because the daemon is already running **all** containers in a privileged mode. |
| 32 | +
|
| 33 | + |
| 34 | +## Deployment Guide |
| 35 | + |
| 36 | +Create a directory called "neo-test" in a directory of your choice to host the configuration files below. |
| 37 | + |
| 38 | +### Environment variables |
| 39 | +First, we need to set up the following .env file to configure the database. |
| 40 | + |
| 41 | +<<< @/projects/neo/examples/env |
| 42 | + |
| 43 | + |
| 44 | +> [!TIP] |
| 45 | +> The usage of [Docker/Podman Secrets](https://docs.docker.com/compose/how-tos/use-secrets/) is another path to explore addressing the challenge of credentials stored locally on a hard drive. |
| 46 | +
|
| 47 | +### Compose Container file |
| 48 | +Download the latest [```neo-containerfile.yml```](/projects/neo/examples/neo-containerfile.yml) or copy its content from: |
| 49 | + |
| 50 | +<<< @/projects/neo/examples/neo-containerfile.yml |
| 51 | + |
| 52 | +### Start the containers |
| 53 | + |
| 54 | +::: code-group |
| 55 | + |
| 56 | +``` [Docker] |
| 57 | +docker compose -f neo-all-in.yml up --build -d |
| 58 | +docker ps |
| 59 | +
|
| 60 | +Expected output: |
| 61 | +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES |
| 62 | +d8bbf02435fb docker.io/library/postgres:16.10-alpine3.21 postgres 7 seconds ago Up 8 seconds 0.0.0.0:5432->5432/tcp neodb |
| 63 | +1aefb8db34e8 ghcr.io/netapp/netapp-copilot-connector:3.1.1 6 seconds ago Up 7 seconds 0.0.0.0:8081->8080/tcp neo |
| 64 | +792aa53a0689 ghcr.io/beezy-dev/neo-ui-framework:3.1.0 5 seconds ago Up 6 seconds 0.0.0.0:8080->80/tcp neoui |
| 65 | +670ec2f91cdf docker.io/dockurr/samba:latest 4 seconds ago Up 4 seconds 0.0.0.0:445->445/tcp neosmb |
| 66 | +
|
| 67 | +Recover logs: |
| 68 | +docker compose -f neo-all-in.yml logs |
| 69 | +``` |
| 70 | + |
| 71 | +``` [Podman] |
| 72 | +sudo podman compose -f neo-all-in.yml up --build -d |
| 73 | +sudo podman ps |
| 74 | +
|
| 75 | +Expected output: |
| 76 | +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES |
| 77 | +d8bbf02435fb docker.io/library/postgres:16.10-alpine3.21 postgres 7 seconds ago Up 8 seconds 0.0.0.0:5432->5432/tcp neodb |
| 78 | +1aefb8db34e8 ghcr.io/netapp/netapp-copilot-connector:3.1.1 6 seconds ago Up 7 seconds 0.0.0.0:8081->8080/tcp neo |
| 79 | +792aa53a0689 ghcr.io/beezy-dev/neo-ui-framework:3.1.0 5 seconds ago Up 6 seconds 0.0.0.0:8080->80/tcp neoui |
| 80 | +670ec2f91cdf docker.io/dockurr/samba:latest 4 seconds ago Up 4 seconds 0.0.0.0:445->445/tcp neosmb |
| 81 | +
|
| 82 | +Recover logs: |
| 83 | +sudo podman compose -f neo-all-in.yml logs |
| 84 | +``` |
| 85 | +::: |
| 86 | + |
| 87 | +You should see logs indicating that the NetApp Neo Core container has started successfully as follows: |
| 88 | + |
| 89 | +```log |
| 90 | +neo | 2025-12-03 19:46:43.882 | INFO | app.main:lifespan:146 - Starting up application... |
| 91 | +neo | 2025-12-03 19:46:43.882 | INFO | app.main:lifespan:150 - 🔧 Setup mode: Skipping license validation and Graph initialization |
| 92 | +neo | 2025-12-03 19:46:43.882 | INFO | app.main:lifespan:151 - 📋 Complete setup via /api/v1/setup endpoints to enable full functionality |
| 93 | +neo | INFO: Application startup complete. |
| 94 | +neo | INFO: Uvicorn running on http://0.0.0.0:8080 (Press CTRL+C to quit) |
| 95 | +``` |
| 96 | + |
12 | 97 |
|
13 | | -## Deployment Steps |
| 98 | +### Configure |
14 | 99 |
|
15 | | -1. **Download the Docker Compose File**: |
16 | | - Download the latest `docker-compose.yml` file from the [NetApp Neo GitHub repository](https://raw.githubusercontent.com/NetApp/Innovation-Labs/refs/heads/main/netapp-neo/dist/docker-compose.yml) to your local machine. |
17 | | -2. **Configure Environment Variables**: |
18 | | - Open the `docker-compose.yml` file in a text editor and configure the necessary environment variables, such as database connection details, admin credentials, and any other required settings. |
| 100 | +#### via GUI |
| 101 | +Neo Console is available at ```http://your.ip:8080``` or ```http://myhost.mydomain.tld:8080``` and will welcome you with the following screen: |
19 | 102 |
|
20 | | - ```yaml |
21 | | - environment: |
22 | | - - DATABASE_URL=postgresql://postgres:yourStrongPasswordHere!@db:5432/neo |
23 | | - ``` |
| 103 | +<img width="1891" height="962" alt="image" src="https://github.com/user-attachments/assets/87732882-7995-4266-83a2-3e31f59c57e8" /> |
24 | 104 |
|
25 | | - For example, if my server's IP address is `10.100.20.05`, my username is `postgres`, the port is `5432` and my password is `yourStrongPasswordHere!`, I would set the `DATABASE_URL` as follows: |
| 105 | +Go to Settings and select the tab Neo Core to start the configuration |
| 106 | +<img width="1891" height="962" alt="image" src="https://github.com/user-attachments/assets/2cfa73d9-33a1-4165-ab25-1628a579c6f6" /> |
26 | 107 |
|
27 | | - ```yaml |
28 | | - environment: |
29 | | - - DATABASE_URL=postgresql://postgres:yourStrongPasswordHere!@10.100.20.05:5432/neo |
30 | | - ``` |
| 108 | +Once a valid license key is entered and saved, the page will refresh to show the following status: |
| 109 | +<img width="1884" height="952" alt="image" src="https://github.com/user-attachments/assets/5ed90473-fb88-4cbe-971f-fe305a73b98a" /> |
31 | 110 |
|
32 | | -3. **Start the Containers**: |
33 | | - Open a terminal, navigate to the directory where the `docker-compose.yml` file is located, and run the following command to start the containers: |
34 | | - ```bash |
35 | | - docker-compose up -d |
36 | | - ``` |
37 | | - This command will download the necessary Docker images and start the NetApp Connector (Neo) along with its dependencies in detached mode. |
38 | | -4. **Verify the Deployment**: |
39 | | - After the containers are up and running, you can verify the deployment by checking the logs: |
| 111 | +At this stage, the M365 Copilot Graph or other settings can be configured now or later. Once the desired configuration is complete, click "Setup Complete". |
| 112 | +This will trigger a restart of Neo's container with the configured settings: |
| 113 | +<img width="1884" height="952" alt="image" src="https://github.com/user-attachments/assets/2711319d-f4f4-47d4-afa8-1b2e037289c6" /> |
40 | 114 |
|
41 | | - ```bash |
42 | | - docker-compose logs -f |
43 | | - ``` |
| 115 | +Once Neo has restarted, the page will reload with the status "Complete", and a button "Admin Credentials" will appear to recover the temporary credentials: |
| 116 | +<img width="1884" height="952" alt="image" src="https://github.com/user-attachments/assets/7db70db5-77dc-4cb9-9472-9fe912c7c0f5" /> |
44 | 117 |
|
45 | | - You should see logs indicating that the NetApp Connector (Neo) has started successfully as follows: |
| 118 | +Credentials |
| 119 | +<img width="1884" height="952" alt="image" src="https://github.com/user-attachments/assets/1e063c89-e210-4c3a-9bbf-110c070b834c" /> |
| 120 | +Updating credentials |
| 121 | +<img width="1884" height="952" alt="image" src="https://github.com/user-attachments/assets/0e602ddb-5d68-49f6-a0bb-1cf82539cb27" /> |
46 | 122 |
|
47 | | - ``` |
48 | | - neo-1 | 2025-12-03 19:46:43.882 | INFO | app.main:lifespan:146 - Starting up application... |
49 | | - neo-1 | 2025-12-03 19:46:43.882 | INFO | app.main:lifespan:150 - 🔧 Setup mode: Skipping license validation and Graph initialization |
50 | | - neo-1 | 2025-12-03 19:46:43.882 | INFO | app.main:lifespan:151 - 📋 Complete setup via /api/v1/setup endpoints to enable full functionality |
51 | | - neo-1 | INFO: Application startup complete. |
52 | | - neo-1 | INFO: Uvicorn running on http://0.0.0.0:8080 (Press CTRL+C to quit) |
53 | | - ``` |
| 123 | +> [!IMPORTANT] |
| 124 | +> This temporary password will not be accessible again once you have logged in with the credentials. |
| 125 | +> Make sure to either save it in your password m(anager or change it in the Users page. |
54 | 126 |
|
55 | | -5. **Access the Web Interface**: |
56 | | - Open your web browser and navigate to `http://<your-server-ip>:8080` to access the NetApp Connector (Neo) web interface. Replace `<your-server-ip>` with the actual IP address of your server. For further information on using the web interface, refer to the [Management](management) section of the documentation. |
| 127 | +<img width="1884" height="952" alt="image" src="https://github.com/user-attachments/assets/ba62c004-d7c1-498c-8082-0af298372d7f" /> |
57 | 128 |
|
58 | | -## Stopping the Deployment |
| 129 | +#### via API |
| 130 | +Neo can also be configured via the API, available at ```http://your.ip:8081/docs``` or ```http://myhost.mydomain.tld:8081/docs```. |
59 | 131 |
|
60 | | -To stop the NetApp Connector (Neo) deployment, run the following command in the terminal where the `docker-compose.yml` file is located: |
| 132 | +## Troubleshooting |
61 | 133 |
|
62 | | -```bash |
63 | | -docker-compose down |
| 134 | +### postgres |
| 135 | + |
| 136 | +Check if the DB was created using both methods to verify the DB and networking at the same time: |
| 137 | + |
| 138 | +::: code-group |
| 139 | + |
| 140 | +```BASH [Docker] |
| 141 | +docker exec -it neodb psql -h localhost -U postgres -l |
| 142 | +``` |
| 143 | + |
| 144 | +```BASH [Podman] |
| 145 | +sudo podman exec -it neodb psql -h localhost -U postgres -l |
| 146 | +``` |
| 147 | +::: |
| 148 | + |
| 149 | +or if you have ```psql``` utils deployed: |
| 150 | +```BASH |
| 151 | +psql -U postgres -h 192.168.122.245 -p 5432 postgres -l |
| 152 | +``` |
| 153 | + |
| 154 | +Expected output: |
| 155 | +``` |
| 156 | +List of databases |
| 157 | + Name | Owner | Encoding | Locale Provider | Collate | Ctype | ICU Locale | ICU Rules | Access privileges |
| 158 | +--------------------+----------+----------+-----------------+------------+------------+------------+-----------+----------------------- |
| 159 | + netappconnectorrom | postgres | UTF8 | libc | en_US.utf8 | en_US.utf8 | | | |
| 160 | + postgres | postgres | UTF8 | libc | en_US.utf8 | en_US.utf8 | | | |
| 161 | + template0 | postgres | UTF8 | libc | en_US.utf8 | en_US.utf8 | | | =c/postgres + |
| 162 | + | | | | | | | | postgres=CTc/postgres |
| 163 | + template1 | postgres | UTF8 | libc | en_US.utf8 | en_US.utf8 | | | =c/postgres + |
| 164 | + | | | | | | | | postgres=CTc/postgres |
| 165 | +(4 rows) |
| 166 | +
|
| 167 | +``` |
| 168 | + |
| 169 | +### Neo |
| 170 | + |
| 171 | +Check the logs and share these with the team for any potential issues you might encounter: |
| 172 | + |
| 173 | +::: code-group |
| 174 | + |
| 175 | +```BASH [Docker] |
| 176 | +docker logs -f neo |
64 | 177 | ``` |
65 | 178 |
|
66 | | -This command will stop and remove the containers and networks created by Docker Compose. Data will be preserved in the volumes defined in the `docker-compose.yml` file. |
| 179 | +```BASH [Podman] |
| 180 | +sudo podman logs -f neo |
| 181 | +``` |
| 182 | +::: |
| 183 | + |
| 184 | +### Neo UI |
| 185 | + |
| 186 | +Check the logs and share these with the team for any potential issues you might encounter: |
| 187 | + |
| 188 | + |
| 189 | +::: code-group |
| 190 | + |
| 191 | +```BASH [Docker] |
| 192 | +docker logs -f neoui |
| 193 | +``` |
| 194 | + |
| 195 | +```BASH [Podman] |
| 196 | +sudo podman logs -f neoui |
| 197 | +``` |
| 198 | +::: |
| 199 | + |
| 200 | +Check the web console in the Browser for additional error messages. |
| 201 | + |
| 202 | + |
| 203 | +### Samba (optional) |
| 204 | + |
| 205 | +Check the logs and share these with the team for any potential issues you might encounter: |
| 206 | + |
| 207 | +::: code-group |
| 208 | + |
| 209 | +```BASH [Docker] |
| 210 | +docker logs -f neosmb |
| 211 | +``` |
| 212 | + |
| 213 | +```BASH [Podman] |
| 214 | +sudo podman logs -f neosmb |
| 215 | +``` |
| 216 | +::: |
67 | 217 |
|
68 | | -This concludes the steps to deploy the NetApp Connector (Neo) using Docker Compose. For more advanced configurations and management options, please refer to the [Management](management) section of the documentation. |
| 218 | +## Next steps |
| 219 | +This concludes the steps to deploy the NetApp Neo Core using Docker/Podman Compose. For more advanced configurations and management options, please refer to the [Management](/projects/neo/core/management.md) section of the documentation. |
0 commit comments