Reviewed-on: #119pull/120/head 1.5.0
commit
aeadf1f648
26
CHANGELOG.md
26
CHANGELOG.md
|
@ -5,56 +5,58 @@ 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.5.0] - 2025-09-11
|
||||
|
||||
### Changed
|
||||
|
||||
- Run sshd earlier in oglive
|
||||
|
||||
## [1.4.7] - 2025-09-10
|
||||
|
||||
## Change
|
||||
### Changed
|
||||
|
||||
- Oggit branch fix
|
||||
|
||||
|
||||
## [1.4.6] - 2025-09-10
|
||||
|
||||
## Change
|
||||
### Changed
|
||||
|
||||
- Oggit branch tracking
|
||||
|
||||
|
||||
## [1.4.5] - 2025-09-09
|
||||
|
||||
## Change
|
||||
### Changed
|
||||
|
||||
- Oggit fast restore
|
||||
|
||||
|
||||
## [1.4.4] - 2025-09-09
|
||||
|
||||
## Change
|
||||
### Changed
|
||||
|
||||
- Oggit Windows EFI boot fixes v2
|
||||
|
||||
|
||||
## [1.4.3] - 2025-09-09
|
||||
|
||||
## Change
|
||||
## #Changed
|
||||
|
||||
- Oggit Windows EFI boot fixes
|
||||
|
||||
## [1.4.2] - 2025-09-09
|
||||
|
||||
## Change
|
||||
### Changed
|
||||
|
||||
- Oggit EFI boot fixes
|
||||
|
||||
## [1.4.1] - 2025-09-05
|
||||
|
||||
## Change
|
||||
### Changed
|
||||
|
||||
- Oggit branch creation fixes
|
||||
- Oggit checked out repo integrity checking
|
||||
|
||||
## [1.4.0] - 2025-08-28
|
||||
|
||||
## Changed
|
||||
### Changed
|
||||
|
||||
- Oggit branch creation support
|
||||
- Oggit parameter refactoring
|
||||
|
|
|
@ -12,7 +12,7 @@ for l in libs: sys.path.insert (0, l)
|
|||
import subprocess
|
||||
|
||||
import ogGlobals
|
||||
from InitLib import loadenviron, write_profile, clean_esp, fileslinks, loadmodules, metadevs, mountrepo, poweroff, filebeat, stunnel, dbus, otherservices, runhttplog
|
||||
from InitLib import loadenviron, write_profile, sshd, clean_esp, fileslinks, loadmodules, metadevs, mountrepo, poweroff, filebeat, stunnel, dbus, otherservices, runhttplog
|
||||
|
||||
IPV4ADDR = os.environ.get ('IPV4ADDR', '')
|
||||
OG_IP = os.environ.get ('OG_IP', '')
|
||||
|
@ -23,6 +23,7 @@ write_profile()
|
|||
# Funciones de inicio.
|
||||
clean_esp()
|
||||
fileslinks()
|
||||
sshd()
|
||||
loadmodules()
|
||||
metadevs()
|
||||
mountrepo()
|
||||
|
|
|
@ -206,7 +206,7 @@ def ogBoot (disk, par, nvramperm=False, params=''):
|
|||
subprocess.run (['dd', 'if=/dev/zero', f'of={mntdir}/ogboot.me', 'bs=1024', 'count=3'])
|
||||
subprocess.run (['dd', 'if=/dev/zero', f'of={mntdir}/ogboot.firstboot', 'bs=1024', 'count=3'])
|
||||
subprocess.run (['dd', 'if=/dev/zero', f'of={mntdir}/ogboot.secondboot', 'bs=1024', 'count=3'])
|
||||
v = RegistryLib.ogGetRegistryValue (mntdir, 'SOFTWARE', r'\Microsoft\Windows\CurrentVersion\Run\ogcleannboot')
|
||||
v = RegistryLib.ogGetRegistryValue (mntdir, 'SOFTWARE', r'\Microsoft\Windows\CurrentVersion\Run\ogcleanboot')
|
||||
if not v:
|
||||
RegistryLib.ogAddRegistryValue (mntdir, 'SOFTWARE', r'\Microsoft\Windows\CurrentVersion\Run\ogcleanboot')
|
||||
RegistryLib.ogSetRegistryValue (mntdir, 'SOFTWARE', r'\Microsoft\Windows\CurrentVersion\Run\ogcleanboot', r'cmd /c del c:\ogboot.*')
|
||||
|
|
|
@ -126,6 +126,9 @@ def fileslinks():
|
|||
for f in glob.glob ('/scripts/ssl/*'):
|
||||
shutil.copy2 (f, '/root/.ssh/')
|
||||
|
||||
def sshd():
|
||||
subprocess.run (['/etc/init.d/ssh', 'start'], capture_output=True, text=True)
|
||||
|
||||
def loadmodules():
|
||||
print (ogGlobals.lang.MSG_LOADMODULES)
|
||||
|
||||
|
@ -294,7 +297,7 @@ def dbus():
|
|||
subprocess.Popen (['dbus-monitor', '--system'], stdout=dbus_mon_fd, stderr=subprocess.STDOUT)
|
||||
|
||||
def otherservices():
|
||||
DEVICE = os.environ.get ('DEVICE', '')
|
||||
DEVICE = os.environ.get ('DEVICE', '')
|
||||
|
||||
if ogIsEfiActive():
|
||||
subprocess.run (['mount', '-t', 'efivarfs', 'none', '/sys/firmware/efi/efivars'])
|
||||
|
@ -309,14 +312,12 @@ def otherservices():
|
|||
if not PASS: PASS = 'og'
|
||||
subprocess.run (['passwd', 'root'], input=f'{PASS}\n{PASS}\n', stderr=subprocess.DEVNULL, text=True)
|
||||
|
||||
subprocess.run (['/etc/init.d/ssh', 'start'], capture_output=True, text=True)
|
||||
|
||||
#setterm -blank 0 -powersave off -powerdown 0 < /dev/console > /dev/console 2>&1 ## apagado de monitor
|
||||
subprocess.run (['ethtool', '-s', DEVICE, 'wol', 'g'], stderr=subprocess.DEVNULL) ## Activado WOL en la interfaz usada en arranque PXE.
|
||||
|
||||
def runhttplog():
|
||||
## si estos accesos a os.environ fallan, es porque loadenviron() no se ejecutó
|
||||
OPENGNSYS = os.environ['OPENGNSYS']
|
||||
OPENGNSYS = os.environ['OPENGNSYS']
|
||||
|
||||
try:
|
||||
shutil.copy2 ('/etc/lighttpd/lighttpd.conf', '/etc/lighttpd/lighttpd.conf.back')
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
#@brief Script para realizar la configuracion del sistema operativo restaurado.
|
||||
#@param 1 disco
|
||||
#@param 2 particion
|
||||
#@param 2 nombre imagen
|
||||
#@param 3 nombre imagen
|
||||
#@return
|
||||
#@TODO comprobar que el tipo de particion corresponde con el sistema de archivos.
|
||||
#@exception OG_ERR_FORMAT # 1 formato incorrecto.
|
||||
|
|
Loading…
Reference in New Issue