Skip to content

Commit

Permalink
Fixes #2216: Jelastc YAML changes added for changing the admin email …
Browse files Browse the repository at this point in the history
…to the installed email
  • Loading branch information
saravanan477 committed May 29, 2019
1 parent 521dfc5 commit 30ccd55
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion Jelastic/jelastic_password.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
require_once '/var/www/webroot/ROOT/server/php/config.inc.php';
require_once '/var/www/webroot/ROOT/server/php/libs/core.php';
$password = $argv[1];
$result = pg_query_params($db_lnk, 'UPDATE users SET password = $1 WHERE username = $2', array(
$email = $argv[2];
$result = pg_query_params($db_lnk, 'UPDATE users SET password = $1, email = $2 WHERE username = $3', array(
getCryptHash($password),
$argv[2],
'admin'
));
4 changes: 3 additions & 1 deletion Jelastic/restyaboard.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ description: Trello like kanban board. Tasks, to-dos, chat, etc.
homepage: https://restya.com/board
appVersion: 0.6.7
engine: php7.2
categories:
- apps/project-management
nodes:
- cloudlets: 16
nodeType: nginxphp
Expand Down Expand Up @@ -50,5 +52,5 @@ onInstall:
- cmd [postgres9]: printf "PGPASSWORD=${nodes.postgres9.password};\nexport PGPASSWORD;\npsql postgres webadmin -c \"CREATE DATABASE restyaboard;\"\npsql -h ${nodes.postgres9.address} -d restyaboard -U webadmin < /tmp/restyaboard_with_empty_data.sql;\n" > /tmp/createDb
- cmd [postgres9]: chmod +x /tmp/createDb && /tmp/createDb
- cmd [nginxphp]: curl -v -L -G -o /var/www/webroot/ROOT/server/php/shell/jelastic_password.php https://raw.githubusercontent.com/RestyaPlatform/board/dev/Jelastic/jelastic_password.txt
- cmd [nginxphp]: php /var/www/webroot/ROOT/server/php/shell/jelastic_password.php ${user.appPassword}
- cmd [nginxphp]: php /var/www/webroot/ROOT/server/php/shell/jelastic_password.php ${user.appPassword} ${user.email}
success: Installation completed. username admin and password ${user.appPassword}

0 comments on commit 30ccd55

Please sign in to comment.