Compare commits

..

4 Commits

Author SHA1 Message Date
PierreGode
a6b4c6a8c5
Merge pull request #120 from PierreGode/PierreGode-patch-5
Create Shellcheck.yaml
2025-06-07 09:25:21 +02:00
PierreGode
75a2abbcfd
Create Shellcheck.yaml 2025-06-07 09:20:03 +02:00
PierreGode
4e71fc8c4a
Merge pull request #119 from PierreGode/PierreGode-patch-4
arcfour-hamac removal prep
2025-06-07 09:14:33 +02:00
PierreGode
2db563e371
arcfour-hamac removal prep 2025-06-07 09:14:19 +02:00
2 changed files with 36 additions and 10 deletions

27
.github/workflows/Shellcheck.yaml vendored Normal file
View File

@ -0,0 +1,27 @@
name: ADconnection.sh Test Pipeline
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
test-adconnection:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Install shellcheck
run: sudo apt-get update && sudo apt-get install -y shellcheck
- name: Shellcheck lint ADconnection.sh
run: shellcheck ./ADconnection.sh
- name: Bash syntax check ADconnection.sh
run: bash -n ./ADconnection.sh
- name: Run ADconnection.sh --help
run: bash ./ADconnection.sh --help

View File

@ -829,7 +829,8 @@ myhost=$( hostname | cut -d '.' -f1 )
clear
sudo apt install adcli -y
sudo echo "${NUMBER}Installing packages do no abort!.......${END}"
if ! sudo apt-get -qq install realmd adcli sssd ntp curl -y && sudo apt-get -qq install -f -y
if ! sudo apt-get -qq install realmd adcli sssd ntp krb5-user curl -y && sudo apt-get -qq install -f -y
then
echo "${RED_TEXT}Failed installing packages, please resolve dpkg and try again ${END}"
exit 1
@ -1089,7 +1090,7 @@ myhost=$( hostname | cut -d '.' -f1 )
clear
sudo apt install adcli -y
sudo echo "${NUMBER}Installing packages do no abort!.......${END}"
if ! sudo apt-get -qq install realmd adcli sssd ntp curl -y && sudo apt-get -qq install -f -y
if ! sudo apt-get -qq install realmd adcli sssd ntp krb5-user curl -y && sudo apt-get -qq install -f -y
then
echo "${RED_TEXT}Failed installing packages, please resolve dpkg and try again ${END}"
exit 1
@ -1577,12 +1578,10 @@ sudo apt install adcli -y
sudo apt-get -qq update
sudo apt-get -qq install libsss-sudo -y
sudo apt-get -qq install adcli -y
sudo apt-get -qq install realmd adcli sssd -y
sudo apt-get -qq install realmd adcli krb5-user sssd -y
sudo apt-get -qq install ntp curl -y
sudo apt-get -qq install policykit-1 -y
sudo mkdir -p /var/lib/samba/private
sudo apt-get -qq install realmd adcli sssd -y
sudo apt-get -qq install ntp -y
sudo apt-get -qq install -f -y
clear
if ! sudo dpkg -l | grep realmd
@ -1737,7 +1736,7 @@ sudo echo "${RED_TEXT}Installing packages do no abort!.......${END}"
sudo apt install adcli -y
sudo apt-get -qq update
sudo apt-get -qq install libsss-sudo -y
sudo apt-get -qq install realmd adcli sssd curl -y
sudo apt-get -qq install realmd adcli krb5-user sssd curl -y
sudo apt-get -qq install ntp -y
sudo apt-get -qq install policykit-1 -y
sudo mkdir -p /var/lib/samba/private
@ -1815,7 +1814,7 @@ fi_auth
CentOS(){
export HOSTNAME
myhost=$( hostname | cut -d '.' -f1 )
yum -y install realmd sssd oddjob oddjob-mkhomedir adcli samba-common-tools samba-common heimdal-clients msktutil
yum -y install realmd sssd oddjob oddjob-mkhomedir adcli krb5-user samba-common-tools samba-common heimdal-clients msktutil
yum -y install adcli=0.8.2-1 -y
yum -y install ipa-client
echo "Looking for domains..."
@ -1910,7 +1909,7 @@ exit
raspberry(){
export HOSTNAME
myhost=$( hostname | cut -d '.' -f1 )
sudo aptitude install ntp adcli sssd
sudo aptitude install ntp adcli sssd krb5-user
sudo mkdir -p /var/lib/samba/private
sudo aptitude install libsss-sudo
sudo systemctl enable sssd
@ -1958,7 +1957,7 @@ exit
Fedora_fn(){
export HOSTNAME
myhost=$( hostname | cut -d '.' -f1 )
yum -y install realmd sssd oddjob oddjob-mkhomedir adcli samba-common-tools samba-common
yum -y install realmd sssd oddjob oddjob-mkhomedir adcli krb5-user samba-common-tools samba-common
DOMAIN=$(realm discover | grep -i realm-name | awk '{print $2}')
if ! ping -c 1 "$DOMAIN"
then