I have developed a press portal for german fire departments. New fire departments should be able to register on my website and a cronjob should automatically create a new Hestia user with subdomain and database and send an email on the end. The whole script should be stored in a bash file.
To make sure that I have not forgotten anything, I ask once in the round whether the logic is correct.
(Example user and domain: department1
)
My hestia script idea:
Only one user, one domain with SSL and one database should be created.
# new user
v-add-user department1 P40w@rD [email protected]
# add subdomain
v-add-domain department1 department1.domain.de
# set docroot (right?)
v-change-web-domain-docroot department1 department1.domain.de public/
# enable ssl
v-add-web-domain-ssl department1 department1.domain.de
# create database
v-add-database department1 department1 department1_portal Password!
After that comes the part with copying the software (git checkout) and generating the .env file with the database connection.
Will this work? Or do I still need to run a Hestia command?
BTW: Does it make sense to create a Hestia user for each department or can everything be managed by one user?
The portal is only accessed via the browser. No one gets database access or anything else.