Commit Graph

6841 Commits

Author SHA1 Message Date
Johannes Zellner 783ec03ac9 The setup views require webServerOrigin for documentation purpose 2019-12-23 17:15:45 +01:00
Girish Ramakrishnan 6cd395d494 Allow restore from error state 2019-12-20 17:58:42 -08:00
Girish Ramakrishnan 681079e01c repair: reconfigure for all other states
the idea was that the failed routes can be called again in other cases
2019-12-20 17:00:53 -08:00
Girish Ramakrishnan 2692f6ef4e Add restart route for atomicity 2019-12-20 11:15:36 -08:00
Girish Ramakrishnan 887cbb0b22 make percent non-zero 2019-12-18 09:33:44 -08:00
Girish Ramakrishnan 93199c7f5b eventlog: support ticket and ssh 2019-12-16 14:06:55 -08:00
Girish Ramakrishnan 4c6566f42f stopped apps should not be updated or auto-updated 2019-12-16 13:29:15 -08:00
Johannes Zellner c38f7d7f93 Make properties explicitly available 2019-12-16 15:21:26 +01:00
Girish Ramakrishnan da85cea329 avatar: remove query param
let the ui add the size and default
2019-12-13 13:45:02 -08:00
Girish Ramakrishnan a7dee6be51 cloudron.runSystemChecks should take a callback 2019-12-12 20:41:03 -08:00
Girish Ramakrishnan 2817dc0603 Not required to run any cron job immediately 2019-12-12 20:39:40 -08:00
Girish Ramakrishnan 6f36c72e88 Fix crash in mail.checkConfiguration 2019-12-12 20:36:27 -08:00
Girish Ramakrishnan 45e806c455 typo in comment 2019-12-12 19:54:59 -08:00
Johannes Zellner bbdd76dd37 Fix and add memory route tests 2019-12-12 13:21:24 +01:00
Johannes Zellner 09921e86c0 Remove redunandant memory property from config
we have a specific route for this now
2019-12-12 12:14:08 +01:00
Girish Ramakrishnan 9dd3e4537a return 422 on instance id mismatch
the ui redirects otherwise
2019-12-11 15:13:38 -08:00
Girish Ramakrishnan ae5722a7d4 eventlog: typo when mail list is removed 2019-12-11 10:05:45 -08:00
Johannes Zellner 4e3192d450 Avoid double dns setup tracking 2019-12-11 14:02:40 +01:00
Johannes Zellner ccca3aca04 Send setup state to get the actually correct ip 2019-12-10 18:01:07 +01:00
Girish Ramakrishnan e4dd5d6434 Fix crash when uploading file 2019-12-09 15:02:51 -08:00
Girish Ramakrishnan 9a77fb6306 acme2: implement post-as-get
https://tools.ietf.org/html/rfc8555#section-6.3
https://community.letsencrypt.org/t/post-as-get-and-empty-payload-instead-of/86720/3
https://community.letsencrypt.org/t/problem-with-renew-certificates-the-request-message-was-malformed-method-not-allowed/107889/17
2019-12-08 19:17:52 -08:00
Girish Ramakrishnan 3ec5c713bf debug: certFilePath is undefined 2019-12-08 18:23:12 -08:00
Girish Ramakrishnan 837fc27e94 canAutoupdateApp now returns bool 2019-12-08 16:55:56 -08:00
Girish Ramakrishnan 9ad6025310 search and replace gone wrong 2019-12-06 13:52:43 -08:00
Girish Ramakrishnan d765e4c619 add a note 2019-12-06 12:39:46 -08:00
Girish Ramakrishnan 16660e083f Also set overwriteDns when manifest is not provided 2019-12-06 12:21:28 -08:00
Girish Ramakrishnan 4e35020a1c Set overwriteDns for install task 2019-12-06 12:11:34 -08:00
Girish Ramakrishnan 111e0bcb5f Fix repair route path 2019-12-06 11:44:41 -08:00
Girish Ramakrishnan d7f9a547fc Disable requiredState check for now
there is a race but this is mitigated by the checkAppState non-db logic
for now
2019-12-06 11:29:35 -08:00
Girish Ramakrishnan 6a64f24e98 Fix repair
If a task fails, we can either:
* allow other task ops to be called - we cannot do this because the ops are fine-grained. for example,
  a restore failure removes many things and calling set-memory or set-location in that state won't
  make sense.

* provide a generic repair route - this allows one to override args and call the failed task
  again. this is what we have now but has the issue that this repair function has to know about all
  the other op functions. for example, for argument validation. we can do some complicated refactoring
  to make it work if we want.

* just a generic total re-configure - this does not work because clone/restore/backup/datadir/uninstall/update
  failure leaves the app in a state which re-configure cannot do anything about.

* allow the failed op to be called again - this seems the easiest. we just allow the route to be called again
  in the error state.

* if we hit a state where even providing extra args, cannot get you out of this "error" state, we have to provide
  some repair route. for example, maybe the container disappeared by some docke error. user clicks 'repair' to
  recreate the container. this route does not have to take any args.

The final solution is:
* a failed task can be called again via the route. so we can resubmit any args and we get validation
* repair route just re-configures and can be called in any state to just rebuild container. re-configure is also
  doing only local changes (docker, nginx)
* install/clone failures are fixed using repair route. updated manifest can be passed in.
* UI shows backup selector for restore failures
* UI shows domain selector for change location failulre
2019-12-06 09:56:09 -08:00
Girish Ramakrishnan 37d7be93b5 Move oldManifest out of restoreConfig 2019-12-06 09:56:03 -08:00
Girish Ramakrishnan 9c809aa6e1 remove dead comment 2019-12-06 09:35:08 -08:00
Girish Ramakrishnan 7ab9f3fa2f re-configure does not require oldConfig
this is only needed when changing location now. the configure()
is now entirely local i.e rebuild local container and the reverse
proxy config
2019-12-06 09:23:58 -08:00
Girish Ramakrishnan ffeb484a10 No need to return args as part of task.get
This reverts commit 831e22b4ff.
This reverts commit 6774514bd2.
2019-12-06 08:42:49 -08:00
Girish Ramakrishnan 2ffb32ae60 Skip moving data if source and target are same 2019-12-06 08:09:43 -08:00
Girish Ramakrishnan 905bb92bad s3: ensure BoxError return 2019-12-05 21:50:44 -08:00
Girish Ramakrishnan 3926efd153 restore: only take non-empty backupId 2019-12-05 21:16:35 -08:00
Girish Ramakrishnan c5e5bb90e3 better error message 2019-12-05 21:16:35 -08:00
Girish Ramakrishnan cea543cba5 On backup error, only set the task error
at some point, the backup ui can show this error
2019-12-05 16:34:40 -08:00
Girish Ramakrishnan a8b489624d fix error messages 2019-12-05 16:27:00 -08:00
Girish Ramakrishnan 49d3bddb62 Show download progress when restoring rsync backups 2019-12-05 15:44:52 -08:00
Girish Ramakrishnan c0ff3cbd22 move progressTag to the end 2019-12-05 15:44:52 -08:00
Girish Ramakrishnan 1de97d6967 do not clear localstorage during in-place import 2019-12-05 12:42:08 -08:00
Girish Ramakrishnan a44a82083e Add backups.testProviderConfig
fields like format/retention won't be validated here since it's only
testing the access credentials
2019-12-05 11:55:53 -08:00
Girish Ramakrishnan d57681ff21 put fqdn in the end 2019-12-05 11:15:21 -08:00
Girish Ramakrishnan e3de2f81d3 setup and clear addons before import 2019-12-05 11:12:40 -08:00
Girish Ramakrishnan e8c5f8164c do not delete data dir for in-place import 2019-12-05 11:01:27 -08:00
Girish Ramakrishnan c07e215148 Use BoxError in on error cases 2019-12-05 09:54:29 -08:00
Girish Ramakrishnan 4bb676fb5c add asserts 2019-12-05 09:32:45 -08:00
Johannes Zellner dbdf86edfc No need to return the same data which the route got passed in 2019-12-05 18:02:57 +01:00