forked from cloudron-apps/gitea-app
Randomize the admin password
This commit is contained in:
parent
bf63f41072
commit
802f014d9f
1 changed files with 4 additions and 1 deletions
5
start.sh
5
start.sh
|
@ -22,6 +22,9 @@ if [[ ! -f /home/cloudron/gogs/custom/conf/app.ini ]]; then
|
|||
touch /home/cloudron/gogs/custom/conf/app.ini
|
||||
chown cloudron:cloudron /home/cloudron/gogs/custom/conf/app.ini
|
||||
|
||||
admin_password=$(pwgen -1)
|
||||
echo "Admin password set to ${admin_password}"
|
||||
|
||||
# this creates the custom/conf/app.ini
|
||||
curl -X POST http://localhost:3000/install \
|
||||
--data db_type=MySQL \
|
||||
|
@ -38,7 +41,7 @@ if [[ ! -f /home/cloudron/gogs/custom/conf/app.ini ]]; then
|
|||
--data smtp_user= \
|
||||
--data smtp_pwd= \
|
||||
--data admin_name=administrator \
|
||||
--data admin_passwd=admin123 \
|
||||
--data admin_passwd=${admin_password} \
|
||||
--data admin_confirm_passwd=admin123 \
|
||||
--data-urlencode admin_email=girish@forwardbias.in
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue