Commit Graph

60 Commits

Author SHA1 Message Date
Steffy Fort 23e03a1ee1
Fix: Remove egrep for grep -E (#680)
Co-authored-by: Steffy Fort <steffy.fort@cozycloud.cc>
2024-03-21 05:54:55 +08:00
BigEd 246f03b461
fixup count of physical cores in discourse-setup (#739)
See also PR #702 for branch master
2023-10-09 15:47:25 +02:00
Jarek Radosz 32d40fc924
FIX: Update the macOS memory check (#632)
`free` is not available by default on macOS
2022-06-14 00:10:43 +02:00
Gabe Pacuilla 241a42ce71
DEV: Ensure secure file permissions by default (#627)
`discourse-setup` will now ensure container definitions are
installed with `0600` permissions mode only.

`launcher` will now throw a warning when an existing container
definition is world-readable.

Also clean up leftover `launcher setup` logic which no longer exists.
Merge pre-existing logic into `check_prereqs` function.
2022-05-03 11:54:24 -04:00
Michael Brown e0da21275f FIX: the output from which confuses an integer comparison
Thanks @ldmosquera for identifying the problem and fix
2021-10-01 17:33:23 -04:00
Joel Uckelman f568633bf0 FIX: Use the return code from which correctly
The return code of which is the number of arguments which failed...
but what we actually want is 0 when at least one of the docker
exectutables is found and nonzero when none are found.
2021-08-06 17:49:22 -03:00
Joel Uckelman 994922639b
FIX: Don't print error message from which when checking docker install (#549)
'which docker.io || which docker' prints an error message when docker.io
is missing, which will be the case on any non-Ubuntu-based system. This
is confusing and not actually an error unless _both_ are missing.
2021-08-06 11:22:46 +10:00
Jay Pfaffman c5a47cd1e8
FIX: discourse-setup stop running container (#528)
This got commented out during testing of the previous commit
2021-02-23 08:52:20 +11:00
Jay Pfaffman cc5b00a49e feature: discourse-setup email config improvements 2021-02-22 16:27:38 -03:00
Jay Pfaffman 3063a97a2c FIX: discourse-setup MAXMIND works correctly
Ouch. This was worse than I thought.

Things fixed:

- consistent formatting (mostly that after `then` was indented by 4, not 2)
- fail if `DISCOURSE_MAXMIND_LICENSE_KEY` is not added to $web_file
- detect if `web_only.yml` exists 
- stop `web_only` if it exists rather than non-existing `app` (but why is it stopping it anyway?)
- don't try to `assert_maxmind_license_key` before `app.yml` exists
2021-02-04 15:53:47 -03:00
Jay Pfaffman 32c7b98716 use $web_file not app.yml
Maybe this will do the trick
2021-02-04 15:53:47 -03:00
Jay Pfaffman 5bc3e708aa FIX: discourse-setup was not adding MAXMIND key
Oops. The line that was supposed to add the MAXMIND line to app.yml was broken.
2021-02-04 15:53:47 -03:00
Jay Pfaffman 991162e778
Support maxmind (#512)
* add prompts for maxmind

* can leave key blank

* include message for removing key

* fix maxmind prompts

* cleanup assert_maxmind_license_key

* remove changes to check_port()

* remove trailing whitespace

* do not remove ip match check

* fix  indent for chech_IP_match

* remove all trailing whitespace
2021-01-22 17:24:46 -08:00
tshenry 3d34d98992
FEATURE: Add validation to admin email prompt in discourse-setup (#514) 2021-01-08 21:08:05 -08:00
Jay Pfaffman 3a4be87a78
UI: discourse-setup tweak dns problem message (#460)
Make the "your domain doesn't resolve" message more clear.
2020-05-11 19:10:24 -03:00
Rafael dos Santos Silva d3e3857ddc
Early hostname check (#456)
* Move hostname check to earlier in the process

* Provide instruction on hostname check failure

* Fix instruction in case of hostname failure
2020-02-19 16:27:34 -03:00
Rafael dos Santos Silva 026a664e77 FEATURE: Default to HTTPS 2019-12-02 17:34:15 -03:00
Todd Sharp 20e812e3d8 Change check for linux memory (#452)
* Change check for linux memory

Some VMs clock in at *just under* 1GB, so checking for 1GB of RAM will miss these.  Instead, check for MB, divide by 1000 and round up.

* Refine the check_linux_memory function

Be a little more precise and only make an exception for VMs with >= 990MB RAM
2019-10-28 12:58:56 +11:00
Ruben Homs b6379984c2 Make port check optional, add y/n prompt (#448) 2019-10-24 11:40:36 +11:00
Andrew Schleifer 72a7bdf04a fallocate swapfile instead of dd 2019-08-22 20:05:58 -03:00
Rafael dos Santos Silva 874fa4d375 Make our swap config compatible with systemd >= 207 (#331) 2018-11-27 18:39:46 +11:00
Rishabh b7298113d2 Improved Let's Encrypt email argument (#400) 2018-07-30 10:14:44 +10:00
Jay Pfaffman 04a06dd05e fix old awk, better error check, fix data.yml for 2container 2018-04-13 05:57:27 -07:00
Jay Pfaffman 275735af30 FIX discourse-setup--better sanity checking 2018-04-05 15:59:32 -07:00
Jeff Atwood 8e7862c4b4
Improve failed to create swap message 2018-01-03 00:01:42 -08:00
Jay Pfaffman f5cf127dd8 Update samples (#387)
* update web_only.yml to match app.yml

* update data.yml to match standalone.yml

* missing quotes around variable

* first attempt at multi install

* fix up start up

* change 2 container command line option to "2container"
2017-12-28 12:15:59 +11:00
Jay Pfaffman 23c730f0ae Update samples (#385)
* update web_only.yml to match app.yml

* update data.yml to match standalone.yml

* missing quotes around variable
2017-12-12 15:48:23 +11:00
Jay Pfaffman 7f2d626012 port checking tweaks 2017-10-13 16:13:13 -07:00
Jay Pfaffman 17f62d8742 fix syntax error. update let's encrypt language. make backups. 2017-06-05 14:57:28 -07:00
Allen Hancock 2391b7fcf8 update bash if/else statements (#342) 2017-03-27 13:21:22 +11:00
Jeff Atwood 1fad33d6e8 remove excess echos for default let's encrypt off 2017-03-26 16:22:23 -07:00
Jay Pfaffman 07f3b11ea6 Warn not to use let's encrypt if hostname doesn't resolve to IP 2017-03-08 14:54:21 -08:00
Jay Pfaffman f17af9519e allow re-run of discourse-setup; pull defaults from standalone.yml 2017-03-03 15:52:14 -08:00
Teemu Heikkilä 965686730d Fix physical core calculation 2016-10-28 21:37:46 +03:00
Simon Gareste e5ec8aa116 Fix core and memory numbers availability on Mac OS X 2016-10-11 11:27:16 +02:00
Simon Gareste 69dcbef505 Fix OS X not knowing the free bash command 2016-10-11 10:12:31 +02:00
Jay Pfaffman bd7e6e26dd EDIT: Fix up messages about memory and swap 2016-09-12 15:11:19 -07:00
Jay Pfaffman f7bb85e6f1 FIX: make swap when mem is <= (not <) 2GB 2016-09-12 15:07:34 -07:00
Jay Pfaffman c87c4b0a3d removed errant echo 2016-09-06 16:21:14 -07:00
Jay Pfaffman 7cf781fc0c Install Docker if it's missing 2016-09-06 22:17:05 +00:00
Jay Pfaffman 1860218967 install docker if it's missing 2016-09-06 21:18:28 +00:00
Jay Pfaffman c6374a12c6 Fix code that tests for RAM and Swap size
Works on DO .5, 1, 2, 4 GB
2016-09-06 20:36:04 +00:00
Matt Palmer 63b6095f1b Escape slashes from smtp_password
Makes sed a whole lot happier about life.
2016-07-26 10:15:08 +10:00
Jeff Atwood 6a9f41e996 add quotes around SMTP_PASSWORD 2016-06-04 15:46:49 -07:00
Jeff Atwood ac1a2d67d5 Ctrl+C based on Twitter poll..
https://twitter.com/codinghorror/status/734294838925885440
2016-05-23 01:13:24 -07:00
Jeff Atwood e81c025088 we require 2GB of swap now 2016-05-16 15:43:29 -07:00
Jeff Atwood 7c2777f949 add SMTP port selection, smarter mailgun handling 2016-05-16 03:27:43 -07:00
Jeff Atwood 33c14f532e remove root warning on swapfile create, since we require root at start now 2016-05-11 16:34:50 -07:00
Jeff Atwood ebdd72f300 add root check since it's required 2016-05-10 15:20:39 -07:00
Jeff Atwood 7802f6799a sudo command redundant on swapfile create 2016-05-10 02:10:06 -07:00