SHARE
TWEET

Untitled

a guest Mar 13th, 2019 49 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/bin/bash
  2. SERVER=
  3. KEY=
  4. # Xenial repo hozzaadasa (csak Ubuntu 18.04-nel)
  5. echo "deb http://hu.archive.ubuntu.com/ubuntu/ xenial universe" >> /etc/apt/sources.list
  6. apt-get update
  7.  
  8. # szukseges segedprogramok telepitese
  9. apt-get -y install apt-transport-spacewalk rhnsd
  10.  
  11. #Xenial repo torlese
  12. tail -n 1 "/etc/apt/sources.list" | wc -c | xargs -I {} truncate "/etc/apt/sources.list" -s -{}
  13.  
  14. #Insecure repok engedelyezese
  15. echo "Acquire::AllowInsecureRepositories "true";" >  /etc/apt/apt.conf.d/90insecure
  16.  
  17. #debutils.py hotfix
  18. locate /usr/share/rhn/up2date_client/debUtils.py | xargs sed -i -e "s/release = '0'/release = 'X'/g"
  19.  
  20. #OSAD segedprogramok telepitese
  21. yes | dpkg -i pyjabber_0.5.0-1.4ubuntu3_xenial2_all.deb
  22.  
  23. yes | dpkg -i osad_5.11.27-1ubuntu1_xenial7_all.deb
  24.  
  25. #SSH cert letoltese
  26. wget http://$SERVER/pub/RHN-ORG-TRUSTED-SSL-CERT -O /usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT
  27.  
  28. #csatlakozas a szerverhez
  29. rhnreg_ks --serverUrl=https://$SERVER/XMLRPC --sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT --activationkey=$KEY
  30. #OSAD server elinditasa es autostart
  31. service osad start
  32. update-rc.d osad defaults
  33.  
  34. #Ellenorzes
  35.  
  36. apt-get update
  37. apt-get update
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top