Conversation
I have updated the tutorial and verified by installing from a new Debian 10 minimal server install twice. I have also (tried) to create a new pull request and answered the comments.
| sudo su - bepasty | ||
| su - bepasty | ||
| # add path to bepasty/.bashrc | ||
| echo "export PATH=\"/home/bepasty/.local/bin:\$PATH\"" >> /home/bepasty/.bashrc |
There was a problem hiding this comment.
use ~/.bashrc here also, see below.
There was a problem hiding this comment.
The above was added to suppress errors from when installing flask & pygmentize during the pip3 install.
There was a problem hiding this comment.
what I meant is that in line 35, you use ~/.bashrc but in line 33 you use >> /home/bepasty/.bashrc to refer to the same file.
i suggest to use >> ~/.bashrc in line 33 also.
There was a problem hiding this comment.
still wondering though: what exactly ends up being in .local/bin when following these instructions?
shouldn't all stuff end up in ./bin of the virtual env we created and activated?
| On the command line as the bepasty user: | ||
| # create trim alias | ||
| ``alias trim="awk '{\$1=\$1};1'"`` | ||
| # remove the top 11 lines + trim spaces at beginning of lines |
There was a problem hiding this comment.
this looks like something that is going to break if we ever change the header of that file.
There was a problem hiding this comment.
so, just remove that, please.
There was a problem hiding this comment.
Fair enough. Do you have any suggestions on an alternative approach to automating this given the amount of manual effort needed to get the config file into a suitable format and the consequences and errors if not?
There was a problem hiding this comment.
the install tutorial is for a manual installation, so it does not need to do everything automated.
| * The user secret in ``bepasty/config.py`` needs to be secure - an easy way | ||
| to create secure random character strings on the command line is: | ||
| ``tr -dc A-Za-z0-9 </dev/urandom | head -c 10 ; echo ''`` |
There was a problem hiding this comment.
the user secret is something a user either interactively / manually enters at the web UI - in that case they will use something that they can remember more easily.
or, they use a password manager, in that case they won't need that script because they'll use the pwmgr to generated the pw.
There was a problem hiding this comment.
ok, so just remove these lines.
| this can also be used to create a long random secure SECRET_KEY value: | ||
| ``tr -dc 'A-Za-z0-9!"#$%&'\''()*+,-./:;<=>?@[\]^_`{|}~' </dev/urandom | head -c 255 ; echo ''`` | ||
| The length of the random character string is set by the head -c $LENGTH. |
There was a problem hiding this comment.
yes, or you can just type a long enough more or less random string, which will be fine also.
you'll never need to enter it, so that's pretty easy without a complicated looking script piece like that.
so, can we just get rid of these pw generating tipps and tricks?
i'ld rather like to keep the docs shorter and simpler than make a shell scripting tips and tricks out of them.
|
@oijn did you see my feedback? |
| Commands to run as user bepasty: | ||
|
|
||
| :: | ||
|
|
||
| # change to user bepasty | ||
| sudo su - bepasty | ||
| su - bepasty |
There was a problem hiding this comment.
strictly taken, line 26 needs to be moved to below current line 31.
|
besides my feedback, one could also add that see that PR: #271 |
|
@oijn do you want to finish this PR? see my feedback. |
I have updated the tutorial and verified by installing from a new Debian 10 minimal server install twice.
I have also (tried) to create a new pull request and answered the comments.