@@ -15,17 +15,15 @@ wget -O - https://apt.releases.hashicorp.com/gpg | sudo gpg --dearmor -o /usr/sh
1515echo " deb [arch=$( dpkg --print-architecture) signed-by=/usr/share/keyrings/hashicorp-archive-keyring.gpg] https://apt.releases.hashicorp.com $( lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/hashicorp.list
1616
1717apt-get update
18- apt-get install -y nano gcc wget jq screen python3-venv python3-pip strip-nondeterminism tree postgresql postgresql-client vault git python3-pip xxd binutils-multiarch openssl nginx
19-
18+ apt-get install -y nano gcc wget jq screen python3-venv python3-pip python3-build strip-nondeterminism tree postgresql postgresql-client vault git xxd binutils-multiarch openssl nginx
2019apt-get install -y diffoscope-minimal --no-install-suggests --no-install-recommends
21- pip install build==1.2.1 wheel==0.43.0 setuptools==61.0 --break-system-packages
2220
2321git clone https://github.com/SourceCode-AI/secure_coding.git /secure_coding
2422
25- echo " listen_addresses='*'" >> /etc/postgresql/15 /main/postgresql.conf
23+ echo " listen_addresses='*'" >> /etc/postgresql/17 /main/postgresql.conf
2624
27- echo " host all all 0.0.0.0/0 scram-sha-256" >> /etc/postgresql/15 /main/pg_hba.conf
28- echo " host all all ::/0 scram-sha-256" >> /etc/postgresql/15 /main/pg_hba.conf
25+ echo " host all all 0.0.0.0/0 scram-sha-256" >> /etc/postgresql/17 /main/pg_hba.conf
26+ echo " host all all ::/0 scram-sha-256" >> /etc/postgresql/17 /main/pg_hba.conf
2927
3028# PG_PASSWD=$(openssl rand -hex 16)
3129sudo -u postgres createdb secure_db
@@ -34,8 +32,9 @@ sudo -u postgres psql --db secure_db -c "create table users (name VARCHAR(255));
3432sudo -u postgres psql --db secure_db -c " insert into users values ('john doe');" ;
3533systemctl restart postgresql
3634
37- # pip3 install build --break-system-packages
3835echo " export VAULT_SKIP_VERIFY=true" >> /etc/bash.bashrc
3936echo " export VAULT_DEV_LISTEN_ADDRESS=0.0.0.0:8200" >> /etc/bash.bashrc
4037echo " export VAULT_ADDR=http://127.0.0.1:8200" >> /etc/bash.bashrc
4138touch /tmp/automation_finished
39+ echo " Installation completed successfully! Rebooting..."
40+ reboot
0 commit comments