This is a Next.js-based application for controlling and monitoring industrial actuators, including solenoid valves, proportional valves, and pumps. The application utilizes Ant Design for its user interface and API client generated by OpenAPI-TS.
- Real-time monitoring and control of actuators
- Support for multiple types of actuators (solenoid valves, proportional valves, and pumps)
- User-friendly interface with interactive sliders and switches
- API client generated using OpenAPI-TS for seamless integration with the backend API
The project is configured to use pnpm as the package manager. If you don't have pnpm installed, you can install it using npm:
corepack enable pnpm
To set up the project, run the following command:
pnpm install
To start the development server, run:
pnpm dev
This will start the Next.js development server, and you can access the application at http://localhost:3000
.
To build the application, run:
pnpm build
This will create a production-ready build of the application.
The application uses the following configuration files:
next.config.js
: Next.js configuration fileopenapi-ts.config.ts
: OpenAPI-TS configuration filepackage.json
: npm package file
The application uses the following environment variables:
Variable | Description |
---|---|
BACKEND_URI | The URI of the backend API |
- BACKEND_URI: This variable specifies the URI of the backend API endpoint that the server-side code will interact with. It is generally safe to use
localhost
or127.0.0.1
if your backend is running on the same server where the Next.js application is deployed.
The API client is generated using OpenAPI-TS and is located in the app/api
directory. To generate the API client, run the following command:
pnpm generate-client
The application includes a Dockerfile
that allows you to containerize the application for easy deployment.