Added Installation instructions.

This commit is contained in:
Brian Mc Cullough 2024-09-09 00:15:10 +02:00
parent 60059613ec
commit b477103830

72
INSTALL.txt Normal file
View file

@ -0,0 +1,72 @@
Start with Debian 12
APT-Install git openssl mkcert postgresql nginx vim make python3-pip python3-venv curl
Apt-Install php-bz2 php-curl php-gd php-intl php-mbstring php-mcrypt php-pdo php-pgsql php-xml php-zip
Apt-Install certbot python3-certbot-nginx golang-go
Create a working directory
cmd: cd <Working Directory>
cmd: git clone https://code.cacert.org/cacert/oidc-registration-php.git
cmd: cd oidc-registration-php
cmd: cp cacert.ini.sample cacert.ini
Edit cacert.ini and set the Database User and Password that you wish to use.
Also set the Domain and Host name in the URL variables.
cmd: cd misc
Edit oidc_db_v2.sql and insert the Database User name chosen above.
As Root: cmd: cp oidc_db_v2.sql /var/lib/postgres
As Root: cmd: su - postgres
cmd: createuser -s -d -e -r -P bdmc ( Pwd: apin1000 )
cmd: createdb oidc_db -O bdmc
cmd: psql oidc_db < oidc_db_v2.sql
Ctrl-D
cmd: cd ..
cmd: mkdir -p $HOME/.local/share/virtualenvs ~/.local/bin
cmd: python3 -m venv $HOME/.local/share/virtualenvs/ansible
cmd: $HOME/.local/share/virtualenvs/ansible/bin/pip install ansible
cmd: ln -s $HOME/.local/share/virtualenvs/ansible/bin/ansible* $HOME/.local/bin/
cmd: export PATH=$HOME/.local/bin:$HOME/go/bin:$PATH
cmd: go install github.com/nicksnyder/go-i18n/v2/goi18n@latest
cmd: git clone --recurse-submodules https://code.cacert.org/cacert/oidc-parent.git
cmd: cd oidc-parent
# cause pull, fetch and other git commands to consider submodules
cmd: git config submodule.recurse true
Edit: deployment/roles/oidc_idp/templates/idp_config.toml.j2
and ensure that the last line contains 'level = "debug"'.
cmd: make
Change into the "deployment" sub-directory
cmd: cd deployment
cmd: ansible-playbook -K 01_install_cacert_oidc.yml
Answer the password question for your user.
cmd: cd ..
cmd: cd ..
As Root: cmd: certbot --nginx -d <your domain name>
From your working directory, do the following As Root:
cmd: cd oidc-registration-php
cmd: cp -r * /var/www/html
cmd: cp ssl-certs/* /usr/local/share/ca-certficates
cmd: update-ca-certificates -f
cmd: cp misc/reverse-proxy.conf /etc/nginx/conf.d
As Root: cmd: ( cd /var/www/html ; mv -i index.html index.html-orig )
Once you are finished, you may change the Background Image, the Logo and the Favicon, as you wish.