Merge pull request 'refs #2526 fix bugs' (#99) from fix-3-bugs into main
ogclient/pipeline/head This commit looks good Details
ogclient/pipeline/tag This commit looks good Details

Reviewed-on: #99
pull/100/head 1.0.1
Natalia Serrano 2025-07-23 15:04:32 +02:00
commit e2500eb491
5 changed files with 12 additions and 5 deletions

View File

@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.0.1] - 2025-07-23
### Fixed
- Fixed small bugs in the py init scripts
## [1.0.0] - 2025-07-18
### Changed

View File

@ -4,8 +4,9 @@
import os
import sys
OPENGNSYS = os.environ.get ('OPENGNSYS', '/opt/opengnsys')
os.environ['PYTHONPATH'] = f'{OPENGNSYS}/lib/python3'
sys.path.insert (0, os.environ['PYTHONPATH'])
libs = [f'{OPENGNSYS}/lib/python3', '/usr/share/opengnsys-modules/python3/dist-packages']
os.environ['PYTHONPATH'] = ':'.join (libs)
for l in libs: sys.path.insert (0, l)
## end
import subprocess

0
ogclient/interfaceAdm/GetGitData 100644 → 100755
View File

View File

@ -10,7 +10,6 @@
#
import os
import sys
sys.path.insert(0, "/usr/share/opengnsys-modules/python3/dist-packages")
import shutil

View File

@ -95,7 +95,8 @@ def clean_esp():
if esp:
esp_disk, esp_par = esp.split()
mntpt = ogMount (esp_disk, esp_par)
os.unlink (f'{mntpt}/boot/grub/grub.cfg')
if os.path.exists (f'{mntpt}/boot/grub/grub.cfg'):
os.unlink (f'{mntpt}/boot/grub/grub.cfg')
ogUnmount (esp_disk, esp_par)
def fileslinks():
@ -227,7 +228,7 @@ def filebeat():
os.chmod (F, 0o600)
subprocess.run (['sed', '-i',
'-e', f's/__OGLOG_IP/{oglog}/g',
'-e', f's/__OGLOG_IP__/{oglog}/g',
'-e', f's/__OGLOG_PORT__/{OPENSEARCH_PORT}/g',
'-e', f's/__OPENSEARCH_PASSWORD__/{PASS}/g',
F