forked from LibreSchool/server-config
Delete add, commit and push commands for working copy.
This commit is contained in:
parent
55d222132b
commit
b998068d63
@ -1,5 +1,7 @@
|
|||||||
# Default password for project #
|
# Default password for project #
|
||||||
|
|
||||||
|
* NS Box root user: `vagrant`
|
||||||
|
* NS Box vagrant user: `vagrant`
|
||||||
* Vault Password: `v4ul+Password!`
|
* Vault Password: `v4ul+Password!`
|
||||||
* amgmt user (server): `DoN0t4g3t!`
|
* amgmt user (server): `DoN0t4g3t!`
|
||||||
* bglug user (client): `s4lamanDr@`
|
* bglug user (client): `s4lamanDr@`
|
||||||
@ -7,28 +9,22 @@
|
|||||||
|
|
||||||
# How to change passwords for production deployments #
|
# How to change passwords for production deployments #
|
||||||
|
|
||||||
|
## *root* and *vagrant* users ##
|
||||||
|
|
||||||
|
These will not be required, since you will not have a virtual machine to
|
||||||
|
manage via *Vagrant*.
|
||||||
|
|
||||||
## Vault password ##
|
## Vault password ##
|
||||||
|
|
||||||
Clone [`client-pull-installation`][2] then, in the working copy, launch following commands:
|
Clone [`client-pull-installation`][2] then, in the working copy, launch following commands:
|
||||||
|
|
||||||
$ git checkout -b mynewbranch
|
|
||||||
$ ansible-vault rekey domainpwd.vault
|
$ ansible-vault rekey domainpwd.vault
|
||||||
|
|
||||||
`ansible-vault` will ask one time the old password and two times the new one.
|
`ansible-vault` will ask one time the old password and two times the new one.
|
||||||
|
|
||||||
Once done with the password, commit the changes and push changes on github:
|
|
||||||
|
|
||||||
$ git add domainpwd.vault
|
|
||||||
$ git commit "Changed vault password"
|
|
||||||
$ git push -u origin mynewbranch
|
|
||||||
|
|
||||||
## *amgmt* user (server-side) ##
|
## *amgmt* user (server-side) ##
|
||||||
|
|
||||||
Clone [`server-config`][1] then, in the working copy, launch following commands:
|
Clone [`server-config`][1] then, in the working copy, generate a new password hash with the follwing command:
|
||||||
|
|
||||||
$ git checkout -b amgmt_change_pwd
|
|
||||||
|
|
||||||
Generate a new password hash with the follwing command:
|
|
||||||
|
|
||||||
$ mkpasswd -m sha-512
|
$ mkpasswd -m sha-512
|
||||||
|
|
||||||
@ -36,12 +32,6 @@ The command would ask for the password to be hashed. Please copy the result stri
|
|||||||
|
|
||||||
Open up the file `roles/init/tasks/mgmtuser.yml`, find out `password:` and then replace previous hash with the one you have just created.
|
Open up the file `roles/init/tasks/mgmtuser.yml`, find out `password:` and then replace previous hash with the one you have just created.
|
||||||
|
|
||||||
After, commit the changes and push to github:
|
|
||||||
|
|
||||||
$ git add roles/init/tasks/mgmtuser.yml
|
|
||||||
$ git commit -m "Changing amgmt user password."
|
|
||||||
$ git push -u origin amgmt_change_pwd
|
|
||||||
|
|
||||||
## *bglug* user (client side but preseeded) ##
|
## *bglug* user (client side but preseeded) ##
|
||||||
|
|
||||||
The definition of password for *bglug* is inside `*.seed` files, inside [`server-config`][1]. Create a new password hash with:
|
The definition of password for *bglug* is inside `*.seed` files, inside [`server-config`][1]. Create a new password hash with:
|
||||||
@ -50,30 +40,19 @@ The definition of password for *bglug* is inside `*.seed` files, inside [`server
|
|||||||
|
|
||||||
Copy the hash in your clipboard; clone the repository, then in the working directory:
|
Copy the hash in your clipboard; clone the repository, then in the working directory:
|
||||||
|
|
||||||
$ git checkout -b bglug_change_pwd
|
|
||||||
$ find . -iname \*.seed -exec $EDITOR {} \;
|
$ find . -iname \*.seed -exec $EDITOR {} \;
|
||||||
|
|
||||||
Within each `*.seed` file, search for the string `user-password-crypted` string and change following hash.
|
Within each `*.seed` file, search for the string `user-password-crypted` string and change following hash.
|
||||||
|
|
||||||
Add, commit and push to github:
|
|
||||||
|
|
||||||
$ git commit -am "Changing bglug password."
|
|
||||||
$ git push -u origin bglug_change_pwd
|
|
||||||
|
|
||||||
## *admin* user (domain valid) ##
|
## *admin* user (domain valid) ##
|
||||||
|
|
||||||
Password must be specified within NethServer interface for the *admin* user and must be absolutely equal to the one contained inside vault file.
|
Password must be specified within NethServer interface for the *admin* user and must be absolutely equal to the one contained inside vault file.
|
||||||
|
|
||||||
Clone [`client-pull-installation`][2], create new branch and modify the password inside `domainpwd.vault`:
|
Clone [`client-pull-installation`][2], create new branch and modify the password inside `domainpwd.vault`:
|
||||||
|
|
||||||
$ git checkout -b admin_change_pwd
|
|
||||||
$ ansible-vault edit domainpwd.vault
|
$ ansible-vault edit domainpwd.vault
|
||||||
|
|
||||||
The system would ask for the vault password. Change the plain text password with your editor, then:
|
The system would ask for the vault password. Change the plain text password with your editor.
|
||||||
|
|
||||||
$ git add domainpwd.vault
|
|
||||||
$ git commit -m "Changed admin password."
|
|
||||||
$ git push -u origin admin_change_pwd
|
|
||||||
|
|
||||||
[1]: https://github.com/bglug-it/server-config
|
[1]: https://github.com/bglug-it/server-config
|
||||||
[2]: https://github.com/bglug-it/client-pull-installation
|
[2]: https://github.com/bglug-it/client-pull-installation
|
||||||
|
Loading…
x
Reference in New Issue
Block a user