diff options
| author | CoprDistGit <infra@openeuler.org> | 2025-12-12 02:43:20 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2025-12-12 02:43:20 +0000 |
| commit | e98bf14342aca60c9819c4c2de5918b0aa5df661 (patch) | |
| tree | 0ae6bb122127111b22d737cc9cda960f13e0d9ce | |
| parent | 3ca66c3141688973fb1aad0028260bf15ade7b3f (diff) | |
automatic import of osmind-aiopeneuler24.03_LTS_SP2openeuler24.03_LTS_SP1openeuler24.03_LTS
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | osmind-ai.spec | 55 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 57 insertions, 0 deletions
@@ -0,0 +1 @@ +/osmind-ai-1.0.0.tar.gz diff --git a/osmind-ai.spec b/osmind-ai.spec new file mode 100644 index 0000000..f235381 --- /dev/null +++ b/osmind-ai.spec @@ -0,0 +1,55 @@ +%define dist_tag %(sed -n 's/.*release \\([0-9]*\\)\.\\([0-9]*\\).*[Ss][Pp]\\([0-9]*\\).*/oe\\1\\2sp\\3/p; t; s/.*release \\([0-9]*\\)\.\\([0-9]*\\).*/oe\\1\\2/p' /etc/openEuler-release) +%global _unitdir /usr/lib/systemd/system + +%ifarch x86_64 +%global go_arch amd64 +%endif +%ifarch aarch64 +%global go_arch arm64 +%endif + +Name: osmind-ai +Version: 1.0.0 +Release: 1.%{?dist_tag} +Summary: OSMind AI Service + +License: MulanPSL-2.0 +URL: https://gitee.com/Victeo/osmind-aiservice +Source0: %{name}-%{version}.tar.gz + +%global debug_package %{nil} +%global _enable_debug_package 0 + +BuildRequires: golang +Requires: systemd + +%description +OSMind AI Service packaged as RPM. + +%prep +%setup -q + +%build +export GOPROXY=https://goproxy.cn,direct +go mod tidy +CGO_ENABLED=0 GOOS=linux GOARCH=%{go_arch} go build -o osmind_agent cmd/einoagent/main.go + +%install +# 创建目录 +install -d -m 755 %{buildroot}/opt/osmind_ai +install -d -m 755 %{buildroot}%{_unitdir} + +# 复制二进制文件 +install -m 755 osmind_agent %{buildroot}/opt/osmind_ai/ + +# 复制 systemd 服务文件 +install -m 644 osmind-ai.service %{buildroot}%{_unitdir}/ + +%files +%dir /opt/osmind_ai +/opt/osmind_ai/osmind_agent +%{_unitdir}/osmind-ai.service + +%changelog +* Tue Sep 16 2025 ShiLei <845621916@qq.com> - 1.0.0-1 +- Initial package @@ -0,0 +1 @@ +eabac4205b1a720792c7200970839417 osmind-ai-1.0.0.tar.gz |
