Commit Graph

17 Commits

Author SHA1 Message Date
cce33ee405 feat: improve feishu notification formatting
- Refactor the message construction in `send_feishu_notification` to use `jq` for better readability and maintainability.
- Update the email and feishu notification content preparation in `main.sh` to use consistent variable names for subject and content.

These changes enhance the clarity of the notification messages and ensure that the code is easier to modify in the future. The use of `jq` also reduces the risk of syntax errors in JSON formatting.
2025-01-04 18:57:33 +08:00
3f4185589d
Merge pull request #1 from okatu-loli/main
feat: 新增飞书通知支持
2025-01-04 18:35:02 +08:00
千石
094fb11580
Update main.sh 2025-01-04 11:14:58 +08:00
千石
8a952a941b
Update config.sh 2025-01-04 11:13:00 +08:00
千石
ae4c4070da
Create feishu_notify.sh 2025-01-04 11:12:27 +08:00
5ba4d8eb58
Create LICENSE 2025-01-03 18:02:15 +08:00
c1e480004a style: format output for synchronization report
- Adjust formatting of the synchronization report output
- Change indentation and bullet points for better readability
- Ensure consistent presentation of start time, end time, and status

These changes improve the clarity and presentation of the synchronization
report, making it easier for users to read and understand the
synchronization statistics and details.
2025-01-03 17:56:20 +08:00
54abd6106f docs: update README for email notification feature
- Add section for email notification configuration
- Include environment variables required for SMTP setup
- Provide examples for complete configuration and crontab usage

This update enhances the documentation by detailing how to
configure email notifications after script execution. It
ensures users can easily set up and utilize this feature,
providing clear examples and necessary environment variables.
2025-01-03 17:45:42 +08:00
2df06bf616 docs: rename REAEME.md to README.md
- Correct the filename from REAEME.md to README.md

This change ensures that the documentation file follows the
conventional naming standard, making it easier for users
and contributors to find the project documentation.
2025-01-03 17:38:42 +08:00
c5bb5ced10 feat: add success repository logging
- Include logging for successful repositories in the output
- Enhance user feedback by listing both successful and failed repositories

This change improves the visibility of the repository mirroring process by
providing a clear distinction between successful and failed operations. Users
can now easily identify which repositories were successfully processed, thus
enhancing the overall usability of the script.
2025-01-03 17:32:21 +08:00
b8b2ee6972 fix: correct jq syntax for updating stats
- Adjusted the jq command for adding values to arrays to use the correct
  syntax for accessing keys.
- Updated the jq command for updating numeric values to use the
  `--argjson` option for proper type handling.

These changes ensure that the script correctly updates the statistics
file without errors, improving the reliability of the data handling.
2025-01-03 17:27:59 +08:00
ca6a80da97 feat: add synchronization statistics logging
- Initialize statistics logging in the mirror script
- Update logging to include total, processed, skipped, success, and failed repositories
- Enhance summary report with detailed statistics after synchronization

This commit introduces a comprehensive logging mechanism for the
repository synchronization process. It tracks various metrics such as
total repositories, processed repositories, and their success or failure
status. This enhancement provides better visibility into the
synchronization process and helps in debugging and monitoring.
2025-01-03 17:26:32 +08:00
f7770955a9 feat: support different SMTP ports for email sending
- Add conditional logic to handle SMTP_PORT 465 for secure
  connections.
- Use standard SMTP for other ports to allow flexibility in
  email server configurations.

This change enhances the email sending functionality by allowing
users to specify different SMTP ports, improving compatibility
with various email service providers. The previous implementation
only supported port 465, which limited its usability.
2025-01-03 17:14:17 +08:00
5821fefcae fix: simplify script execution command
- Remove unnecessary 'true ||' condition from the
  command that calls mirror.sh.
- This change clarifies the intent of the command and
  ensures that the script executes as expected.
2025-01-03 17:10:27 +08:00
534a9ab0e4 feat: add email notification and logging features
- Introduce email notification configuration options in the README
- Create a new config.sh file for managing environment variables
- Implement mail.sh for sending email notifications
- Add logging functionality to main.sh for tracking synchronization processes

These changes enhance the functionality of the script by allowing users to receive email notifications about the synchronization status and maintain logs of the operations performed. The new configuration options provide flexibility in managing email settings and improve the overall usability of the tool.
2025-01-03 17:03:01 +08:00
bf753e1255 feat: add GitHub to Gitea mirror script
- Create a new shell script for mirroring GitHub repositories to Gitea.
- Implement configuration options for GitHub and Gitea credentials.
- Add functionality to skip specific repositories during synchronization.
- Include error handling and logging for better debugging.
- Provide detailed usage instructions and environment variable setup.

This commit introduces a new feature that automates the process of
mirroring GitHub repositories to a Gitea instance. It supports batch
synchronization, allows skipping certain repositories, and includes
a robust error handling mechanism. The script is designed to be
used with crontab for scheduled execution, making it suitable for
regular backups of GitHub repositories to Gitea.
2025-01-03 15:36:19 +08:00
0b7323897f feat: add colocation agent helm chart and sync scripts
- Introduced a new Helm chart for the colocation agent
- Added scripts for syncing images with Skopeo and downloading Helm charts
- Created necessary configuration files and templates for Kubernetes deployment
- Removed obsolete files related to previous implementations

This commit enhances the deployment capabilities of the colocation agent and provides tools for managing Helm charts and Docker images effectively.
2025-01-03 14:06:28 +08:00