-
Notifications
You must be signed in to change notification settings - Fork 623
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implemented "--unattended" option (Issue #223) #224
Conversation
Due to discontinuation of Google Spaces
UNTESTED!
Merging changes into test branch
auto_install/install.sh
Outdated
confNetwork | ||
confOVPN | ||
|
||
# ?? Is this always OK? Also if you only select one DNS server ?? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this always OK? Also if you only select one DNS server, i.e. OVPNDNS2
is empty?
} | ||
|
||
|
||
# I suggest replacing some of these names. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest replacing some of these names. It looks cleaner in the parameter file.
echo "pivpnUser=${pivpnUser}" | ||
echo "UNATTUPG=${UNATTUPG}" | ||
echo "pivpnInterface=${pivpnInterface}" | ||
echo "IPv4dns=${IPv4dns}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we save IPv4dns
? Or is it fine to just detect it?
Is there a way to update without generating new keys? I read the wiki about just not updating, but it might be a good time to add this now. |
fixed a typo replaced tabs with spaces
I am not sure why this statement does not work with -e. We can also remove the set -e statement altogether.
::: Create a client ovpn profile, optional nopass ::: ::: Usage: pivpn <-a|add> [-n|--name <arg>] [-p|--password <arg>]|[nopass] [-h|--help] ::: ::: Commands: ::: nopass Create a client without a password ::: -n,--name Name for the Client (default: 'raspberrypi') ::: -p,--password Password for the Client (no default) ::: -h,--help Show this help dialog
::: Revoke a client ovpn profile ::: ::: Usage: pivpn <-r|revoke> [-h|--help] [<client-1>] ... [<client-n>] ... ::: ::: Commands: ::: [none] Interactive mode ::: <client> Client(s) to to revoke ::: -h,--help Show this help dialog
because it is hardcoded as "server" in other scripts
I also added command line options for the pivpn add and pivpn revoke functions. Now I can fully automate the setup and send myself an email with the certificate when everything is installed. :) |
Can anyone help me updating the bash-completion file? |
@EWouters man I just saw this now. been really swamped. Let me review and give you some comments but thanks a ton for this. |
@EWouters this is looking good so far. I've only looked at it online. Will test on real devices to see if it broke anything somewhere. But looks good reading it, awesome job. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still looking good. will merge into test so I can do more live testing.
Great, I'm happy to make any improvements you might suggest. There are also still a few comments in the code where I wasn't sure what was the best approach. |
Any word on this PR? Movement seems to have stalled? |
Hi @troyfontaine , The code was tested and merged into the master, and most of the suggestions and things I was not sure about have since been fixed or became obsolete. Only a few things (like the bash-completion file and the comment on this line) remain to be fixed/checked, but I don't know how to do that. Are you referring to anything specific? And have you tried the --unattended option? Anyway it might be a good idea to check if there were any substantial improvements in the pi-hole installer since this rewrite. I basically ported all the things they did there to this installer. |
I ported the functionality from the pi-hole script to fix #223 (#86). I finished implementing it but more people should try it before merging.
/etc/pivpn/setupVars.conf
Moved some stuff around.
This request is ready for testing.