25 Commits

Author SHA1 Message Date
Jose Diaz-Gonzalez
dac566e75e refactor: move all shellcheck disable definitions to .shellcheckrc file
This makes standard use of shellcheck work without needing to provide extra configuration anywhere.

Also remove use of inline 'shellcheck disable' calls that are already defined in the .shellcheckrc and don't need to be set inline.
2023-08-05 10:58:57 -04:00
Jose Diaz-Gonzalez
28027b9a78 chore: run shfmt 2022-12-26 16:41:45 -05:00
Jose Diaz-Gonzalez
a1c768b9b3 refactor: drop web installer in favor of setup via cli
This makes the installation a bit more secure by ensuring a user does not accidentally expose a way for unauthorized users to add new ssh keys to the system.

Additionally, this removes the extra HOSTNAME file to make the initial install process easier (that file was not modifiable by any dokku commands.

Closes #2247
2021-08-07 16:36:41 -04:00
Tan Jay Jun
58a7e535dd Redirect missing key_file warning to stderr 2019-10-23 10:54:56 +08:00
Jerry Smith
80b20ec4c1 Fixes for issue #3717
* Adjusts documentation
* Changes error messages when ssh key is not present
* Moves error messages to stderr
* Removes erroneous exit line
2019-10-22 20:22:03 -05:00
Jose Diaz-Gonzalez
a9ce738f68 feat: add openresty and runit support to packaging
Our docker image uses runit instead of init/systemd, hence the added sv support on Ubuntu operating systems.
2019-09-16 03:03:20 -04:00
Jose Diaz-Gonzalez
86795ddacc tests: run mvdan/shfmt on test runs
While I do not agree with _every_ style change, this will force Dokku to have consistent formatting across all shell scripts, which is arguably a Good Thing™.

The command used to reprocess everything is:

```shell
shfmt -l -bn -ci -i 2 -w .
```
2019-01-07 01:25:55 -05:00
Jose Diaz-Gonzalez
212ef01f7a fix: revert reload and start commands 2018-03-07 23:43:40 -05:00
Jose Diaz-Gonzalez
b417508c98 fix: handle stopped nginx during debian installation
Closes #3019
2018-03-07 23:32:52 -05:00
Jose Diaz-Gonzalez
79a7342808 Check that the confmodule is sourceable before sourcing it 2016-06-09 12:48:54 -04:00
Jeroen van Baarsen
2a4155aefc Add skip_keyfile option for deb package
There are cases where we don't want the check for keyfile, this will add a
config option, that allows you to skip this particular check.

Fixes #1851

Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
2016-01-12 17:11:13 +01:00
Jose Diaz-Gonzalez
1314b3942d Correctly handle dokku-installer init file creation on systemd instances
- Use the nginx.conf file's existence as a check for whether we should start the service or not
- Create the init files with the dokku-installer.py file. This adds actual systemd support.
- Also ensure we *always* start the service, regardless of it's status. This fixes an issue with processing systemd output
2016-01-01 21:37:42 -05:00
Jose Diaz-Gonzalez
ae2b2febe9 Enable debugging support to debian preinst hook
It is now possible to turn on debugging during an apt-get run by using `TRACE=1`
2015-12-31 08:22:38 -05:00
Jose Diaz-Gonzalez
e323770f89 Replace dokku-installer.rb with dokku-installer.py
The python version should allow us to remove any ruby dependencies and should also slightly speed up dokku installation. All LSB-compliant distributions should have python, so we should be okay depending upon it.

Closes #1783
Closes #1786
2015-12-22 01:59:23 -05:00
Jose Diaz-Gonzalez
626cd958a5 Fallback to using /etc/init.d/nginx reload directly to restart nginx. Closes #1165. Refs #1247 2015-06-25 10:38:47 -04:00
Michael Hobbs
140f5a4939 fix lintball from #1198 2015-05-19 09:39:27 -07:00
3onyc
c2c18af425 Check web_config before key_file (Fixes #1196) 2015-05-19 15:11:06 +02:00
3onyc
d9a989d6b0 Use debconf to allow for command-line or unattended installation 2015-05-15 17:43:40 +02:00
David Jelic
d5ceda6da7 handle upgrade in debian/preinst script 2015-02-10 11:47:20 +01:00
Jose Diaz-Gonzalez
4656e80ab8 Move dokku-installer start to postinst
Performing the start in preinst meant that the required dokku-installer.rb file was not yet in position.
2015-01-16 16:52:50 -05:00
Jose Diaz-Gonzalez
20bb7caef4 Change dokku-installer.rb path to the contrib directory
This should avoid issues when testing via vagrant where the /root/dokku directory is not yet mounted. This is also more correct for cloud-installs
2015-01-16 16:52:50 -05:00
Jose Diaz-Gonzalez
d9026a9974 Remove configuration files if they already exist 2015-01-16 16:52:50 -05:00
Jose Diaz-Gonzalez
3fdc1d20b6 Only start the dokku-installer if it's not already running
Upgrades from previous - fresh - dokku versions will fail if the dokku-installer is already running.
2015-01-16 16:52:50 -05:00
Jose Diaz-Gonzalez
0fcc541e4f Force remove sites-enabled directory, even when empty 2015-01-16 16:52:50 -05:00
Jose Diaz-Gonzalez
b6767f8efc Add new make targets to build and install dokku debian packages 2015-01-16 16:52:50 -05:00