* feat: add more test code Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test code Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test code Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: init project Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: init project Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add versionchecker deploy Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: fix go work go version and build scripts Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: fix actions no pass Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: fix chat bug Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test project Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test project Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test project Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: sava images file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add test file Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set more help and port set Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: update slack link Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: update slack link Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test project Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: update openim-web Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set more help and port set Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: update openim-web Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: update openim-web Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add docker buildx images is openim-web Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add docker buildx images is openim-web Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more test Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: scripts fix Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: scripts fix Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: scripts fix Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set config file path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set config file path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: set config file path Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: docker compose Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: kafka environment port Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: kafka environment port Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: kafka environment port Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: kafka environment port Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * docs: fix docs link error issus:#968 Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * docs: add deployment docs Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more helm chart Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: add more helm chart Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * feat: Optimize the functionality of iam Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: add iam super feat Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: add go format Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> * fix: add go format Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com> --------- Signed-off-by: Xinwei Xiong(cubxxw-openim) <3293172751nss@gmail.com>
OpenIM Suite Scripts
The OpenIM Suite represents a comprehensive collection of scripts, each tailored to manage and operate specific services within the OpenIM ecosystem. These scripts offer consistent, reliable, and efficient tools for initializing, controlling, and managing various OpenIM services on a Linux platform.
Features
- Robustness: Built with Bash's error handling mechanisms (
errexit
,nounset
, andpipefail
), ensuring scripts fail fast and provide relevant error messages. - Modularity: Each script is dedicated to a particular service, promoting clarity and ease of maintenance.
- Comprehensive Logging: Integrated logging utilities offer real-time insights into operations, enhancing transparency and debuggability.
- Systemd Integration: Where applicable, scripts integrate with the systemd service manager, offering standardized service controls like start, stop, restart, and status checks.
Scripts Overview
- openim-api: Control interface for the OpenIM API service.
- openim-cmdutils: Utility toolkit for common OpenIM command-line operations.
- openim-crontask: Manages the OpenIM CronTask service, with both direct and systemctl installation methods.
- openim-msggateway: Script to operate the OpenIM Message Gateway service.
- openim-msgtransfer: Manages the OpenIM Message Transfer functionalities.
- openim-push: Interface for controlling the OpenIM Push Notification service.
- openim-rpc-auth: Script dedicated to the OpenIM RPC Authentication service.
- openim-rpc-conversation: Manages operations related to the OpenIM RPC Conversation service.
- openim-rpc-friend: Control interface for the OpenIM RPC Friend functionalities.
- openim-rpc-group: Script for managing the OpenIM RPC Group service.
- openim-rpc-msg: Operates the OpenIM RPC Messaging service.
- openim-rpc-third: Script dedicated to third-party integrations with OpenIM RPC.
- openim-rpc-user: Control interface for OpenIM RPC User operations.
OpenIM Server Installation Script Usage
The scripts within the OpenIM Suite generally adhere to two primary execution methodologies. To illustrate these methodologies, we'll use openim-crontask
as a representative example.
-
Direct Script Execution: Running the script directly, typically for straightforward start/stop operations.
./[script-name].sh
-
Function-based Execution: Invoking specific functions within the script for more specialized operations (e.g., install, uninstall).
./scripts/install/install.sh [options]
Description:
This script is designed to handle the installation, uninstallation, and status checking of OpenIM components on the server. OpenIM is a presumed communication or messaging platform.
Commands:
-
-i, --install:
Initiate the installation of all OpenIM components. -
-u, --uninstall:
Uninstall or remove all OpenIM components from the server. -
-s, --status:
Check and report the current operational status of the installed OpenIM components. -
-h, --help:
Display the help menu for available commands.
Example Usage:
To install all OpenIM components:
./scripts/install/install.sh -i
or
./scripts/install/install.sh --install
Note
: Ensure you have the necessary privileges to execute installation or uninstallation operations. It's generally recommended to take a backup before making major changes.
1. Direct Script Execution
This method involves invoking the script directly, initiating its default behavior. For instance, with openim-crontask
, direct execution will start the OpenIM CronTask as a background process.
Example:
./openim-crontask.sh
Upon execution, the script will source any necessary configurations, log the start of the CronTask, and finally run the CronTask in the background. The log messages will provide feedback about the process, ensuring the user is informed of the task's progress.
2. Function-based Execution
This approach is more specialized, enabling users to call specific functions defined within the script. This is particularly useful for tasks like installation, uninstallation, and status checks.
For the openim-crontask
script:
-
Installation: It includes building the service, generating configuration files, setting up systemd services, and starting the service.
./openim-crontask.sh openim::crontask::install
-
Uninstallation: Stops the service, removes associated binaries, configuration files, and systemd service files.
./openim-crontask.sh openim::crontask::uninstall
-
Status Check: Verifies the running status of the service, checking for active processes and listening ports.
./openim-crontask.sh openim::crontask::status
It's crucial to familiarize oneself with the available functions within each script. This ensures optimal utilization of the provided tools and a deeper understanding of the underlying operations.
Notes
- Always ensure you have the correct permissions before executing any script.
- Environment variables may need to be set or sourced depending on your installation and configuration.