Compare commits

...

71 commits

Author SHA1 Message Date
Girish Ramakrishnan 95403b326b Version 1.13.2 2024-05-31 10:00:44 +02:00
Girish Ramakrishnan 870718ad69 Update ruby to 3.2.3 2024-05-31 09:19:27 +02:00
Girish Ramakrishnan 95c055755e Update test packages 2024-05-31 08:42:01 +02:00
Girish Ramakrishnan f22270c707 Update Mastodon to 4.2.9 2024-05-31 08:33:20 +02:00
Johannes Zellner de786e59ed Bump version 2024-02-23 16:57:55 +01:00
Johannes Zellner 0c77e8c32a Update for closed regsitration release 2024-02-23 16:45:18 +01:00
Johannes Zellner 6fa11cf195 Update test deps 2024-02-23 15:38:53 +01:00
Johannes Zellner b72b058f5e Update to 4.2.8 2024-02-23 15:38:34 +01:00
Johannes Zellner 77f9fa9a63 Bump version 2024-02-16 13:33:45 +01:00
Johannes Zellner 56bcb395dc Update test deps 2024-02-16 13:19:30 +01:00
Johannes Zellner a24ad995de Update to 4.2.7 2024-02-16 13:19:22 +01:00
Vladimir D f8c84b6ef5 migrateUsers.js: logic updated to resume if failed 2024-02-15 20:46:05 +04:00
Vladimir D a08af787d7 migrateUsers.js updated to use username instead of email 2024-02-15 17:18:05 +04:00
Vladimir D e556c856f1 migrate LDAP users to OIDC 2024-02-15 15:50:03 +04:00
Johannes Zellner 25292a86b4 Make tests language independent 2024-02-14 18:05:43 +01:00
Vladimir D 146b5ac17e OIDC auth implemented, tests updated 2024-02-14 18:05:43 +01:00
Johannes Zellner fdc4e20c77 Bump version 2024-02-14 18:05:43 +01:00
Johannes Zellner 886f27ec9a Update to 4.2.6 2024-02-14 18:02:59 +01:00
Johannes Zellner 941292bf52 Bump version 2024-02-01 17:29:01 +01:00
Johannes Zellner b4f7038f79 Update test deps 2024-02-01 17:07:25 +01:00
Johannes Zellner b77a74978c Update to 4.2.5 2024-02-01 17:07:16 +01:00
Girish Ramakrishnan 816ac7c8ba Version 1.12.4 2024-01-24 16:55:30 +01:00
Girish Ramakrishnan 31ab0ce6c5 Update test packages 2024-01-24 16:32:49 +01:00
Girish Ramakrishnan 6d274756a3 Update mastodon to 4.2.4 2024-01-24 16:21:33 +01:00
Johannes Zellner 246c44e1c3 Bump version 2023-12-05 15:54:03 +01:00
Johannes Zellner 46cf00f343 Update test deps 2023-12-04 16:49:56 +01:00
Johannes Zellner 2938d2cc2f Bump version 2023-12-04 16:49:34 +01:00
Girish Ramakrishnan 1814d12d23 Version 1.12.1 2023-10-11 09:32:31 +05:30
Girish Ramakrishnan 0e6a4c6ec3 Update mastodon to 4.2.1 2023-10-11 08:45:30 +05:30
Girish Ramakrishnan 4036cfa1a7 install ruby into cloudron home dir 2023-10-10 20:00:15 +05:30
Girish Ramakrishnan 27d68b5c35 Update base image 2023-10-10 19:46:52 +05:30
Girish Ramakrishnan 7439769e52 Version 1.12.0 2023-09-22 08:49:37 +05:30
Girish Ramakrishnan 2a87a826c4 Fix test 2023-09-22 08:13:33 +05:30
Girish Ramakrishnan dd4bf3e639 Disable update check 2023-09-21 23:26:45 +05:30
Girish Ramakrishnan f7d9238818 Update mastodon to 4.2.0 2023-09-21 23:22:16 +05:30
Johannes Zellner be85153324 Update test deps 2023-09-20 18:30:31 +02:00
Johannes Zellner 5cdb738996 Bump version 2023-09-20 18:29:48 +02:00
Girish Ramakrishnan 0ccd723d02 Version 1.11.10 2023-09-19 21:56:44 +05:30
Girish Ramakrishnan a24af7b9e1 Update mastodon to 4.1.8 2023-09-19 21:20:51 +05:30
Girish Ramakrishnan b1a3f751f8 Version 1.11.9 2023-09-06 08:56:51 +05:30
Girish Ramakrishnan bd313d9eee Update Mastodon to 4.1.7 2023-09-06 08:13:06 +05:30
Johannes Zellner 464f74713d Bump version 2023-07-31 15:32:35 +02:00
Johannes Zellner 7834da2da1 Bump version 2023-07-31 15:31:31 +02:00
Johannes Zellner 55d80d433d Update test deps 2023-07-21 17:51:19 +02:00
Johannes Zellner 83e912931b Bump version 2023-07-21 17:50:50 +02:00
Johannes Zellner 0f61e3c04e Bump version 2023-07-21 17:49:31 +02:00
Girish Ramakrishnan aea9602460 Version 1.11.6 2023-07-08 07:24:44 +05:30
Girish Ramakrishnan 9ad54e9d7c Update mastodon to 4.1.4 2023-07-08 06:44:59 +05:30
Girish Ramakrishnan cea9af6011 typo in LDAP_PASSWORD - https://docs.joinmastodon.org/admin/config/#ldap_password 2023-07-06 20:35:45 +05:30
Girish Ramakrishnan db96875255 Version 1.11.5 2023-07-06 19:54:25 +05:30
Girish Ramakrishnan 56896d2d63 Add CSP changes 2023-07-06 19:44:01 +05:30
Girish Ramakrishnan 6b25821972 Update test packages 2023-07-06 19:40:15 +05:30
Girish Ramakrishnan 5a079c338c Update mastodon to 4.1.3 2023-07-06 19:40:15 +05:30
Johannes Zellner f01e2215b0 Move cleanup cron job into the night 2023-05-15 12:40:10 +02:00
Johannes Zellner 2878641da2 Also prune accounts 2023-05-13 18:22:52 +02:00
Johannes Zellner 064dd101f3 Add more cache cleanup commands 2023-05-13 13:33:03 +02:00
Johannes Zellner 53ac4525b0 Update test deps 2023-04-26 13:13:32 +02:00
Johannes Zellner 9962369a21 Bump version 2023-04-26 13:13:21 +02:00
Johannes Zellner 90b0f3dd95 Print retention days 2023-04-26 13:13:05 +02:00
Johannes Zellner cef9a1bdbd Allow to set cache retention days 2023-04-26 13:04:46 +02:00
Johannes Zellner 4b80104980 Reduce media caching to 1 day 2023-04-20 23:19:55 +02:00
Johannes Zellner 549c36e136 Update test deps 2023-04-04 14:12:13 +02:00
Johannes Zellner cae51adfbb Bump version 2023-04-04 14:06:00 +02:00
Girish Ramakrishnan c10fe95802 Version 1.11.2 2023-04-02 21:07:28 +02:00
Girish Ramakrishnan 87bf394ab2 Update nginx config
Note the STS headers are sent even if we comment it out in nginx because it apparently
comes from rails 6.1 - https://github.com/mastodon/mastodon/issues/17083
2023-04-02 20:33:48 +02:00
Johannes Zellner 9875b989c5 Update test deps 2023-03-17 12:46:36 +01:00
Johannes Zellner 753025a893 Bump version 2023-03-17 12:46:24 +01:00
Girish Ramakrishnan a761bb52eb Version 1.11.0 2023-02-11 09:44:28 +01:00
Girish Ramakrishnan 97e71fc637 better xpath 2023-02-11 09:42:44 +01:00
Girish Ramakrishnan 07b6993803 Update test packages 2023-02-11 09:09:48 +01:00
Girish Ramakrishnan ef0dab2ecd Update mastodon to 4.1.0 2023-02-11 08:13:34 +01:00
12 changed files with 1119 additions and 376 deletions

239
CHANGELOG
View file

@ -240,3 +240,242 @@
[1.10.0]
* Update base image to 4.0.0
[1.11.0]
* Update Mastodon to 4.1.0
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.0)
* Add support for importing/exporting server-wide domain blocks (enbylenore, ClearlyClaire, dariusk, ClearlyClaire)
* Add listing of followed hashtags (connorshea)
* Add support for editing media description and focus point of already-sent posts (ClearlyClaire)
* Add follow request banner on account header (ClearlyClaire)
* Add confirmation screen when handling reports (ClearlyClaire, Gargron, tribela)
* Add option to make the landing page be /about even when trends are enabled (ClearlyClaire)
[1.11.1]
* Update Mastodon to 4.1.1
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.1)
* Add redirection from paths with url-encoded @ to their decoded form (thijskh)
* Add lang attribute to native language names in language picker in Web UI (ClearlyClaire)
* Add headers to outgoing mails to avoid auto-replies (ClearlyClaire)
* Add support for refreshing many accounts at once with tootctl accounts refresh (9p4)
* Add confirmation modal when clicking to edit a post with a non-empty compose form (PauloVilarinho)
* Add support for the HAproxy PROXY protocol through the PROXY_PROTO_V1 environment variable (CSDUMMI)
* Add SENDFILE_HEADER environment variable (Gargron)
* Add cache headers to static files served through Rails (Gargron)
* Increase contrast of upload progress bar background (toolmantim)
* Change post auto-deletion throttling constants to better scale with server size (ClearlyClaire)
* Change order of bookmark and favourite sidebar entries in single-column UI for consistency (TerryGarcia)
* Change ActivityPub::DeliveryWorker retries to be spread out more (ClearlyClaire)
* Fix “Remove all followers from the selected domains” also removing follows and notifications (ClearlyClaire)
* Fix streaming metrics format (emilweth, emilweth)
* Fix case-sensitive check for previously used hashtags in hashtag autocompletion (deanveloper)
* Fix focus point of already-attached media not saving after edit (ClearlyClaire)
* Fix sidebar behavior in settings/admin UI on mobile (wxt2005)
* Fix inefficiency when searching accounts per username in admin interface (ClearlyClaire)
* Fix duplicate “Publish” button on mobile (ClearlyClaire)
* Fix server error when failing to follow back followers from /relationships (ClearlyClaire)
* Fix server error when attempting to display the edit history of a trendable post in the admin interface (ClearlyClaire)
* Fix tootctl accounts migrate crashing because of a typo (ClearlyClaire)
* Fix original account being unfollowed on migration before the follow request to the new account could be sent (ClearlyClaire)
* Fix the “Back” button in column headers sometimes leaving Mastodon (c960657)
* Fix pgBouncer resetting application name on every transaction (Gargron)
* Fix unconfirmed accounts being counted as active users (ClearlyClaire)
* Fix /api/v1/streaming sub-paths not being redirected (ClearlyClaire)
* Fix drag'n'drop upload area text that spans multiple lines not being centered (vintprox)
* Fix sidekiq jobs not triggering Elasticsearch index updates (ClearlyClaire)
* Fix tags being unnecessarily stripped from plain-text short site description (c960657)
* Fix HTML entities not being un-escaped in extracted plain-text from remote posts (c960657)
* Fix dashboard crash on ElasticSearch server error (ClearlyClaire)
* Fix incorrect post links in strikes when the account is remote (ClearlyClaire)
* Fix misleading error code when receiving invalid WebAuthn credentials (ClearlyClaire)
* Fix duplicate mails being sent when the SMTP server is too slow to close the connection (ClearlyClaire)
* Change user backups to use expiring URLs for download when possible (Gargron)
* Add warning for object storage misconfiguration (ClearlyClaire)
[1.11.2]
* Update nginx config
[1.11.3]
* Update Mastodon to 4.1.2
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.2)
* Fix crash in tootctl commands making use of parallelization when Elasticsearch is enabled (ClearlyClaire, ClearlyClaire)
* Fix crash in db:setup when Elasticsearch is enabled (rrgeorge)
* Fix user archive takeout when using OpenStack Swift or S3 providers with no ACL support (ClearlyClaire)
* Fix invalid/expired invites being processed on sign-up (ClearlyClaire)
* Update Ruby to 3.0.6 due to ReDoS vulnerabilities (saizai)
* Fix unescaped user input in LDAP query (ClearlyClaire)
[1.11.4]
* Allow to customize cache retention days
* Cleanup accounts cache
[1.11.5]
* Update Mastodon to 4.1.3
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.3)
* fixing multiple critical security issues (CVE-2023-36460, CVE-2023-36459)
* Change OpenGraph-based embeds to allow fullscreen (ClearlyClaire)
* Change AccessTokensVacuum to also delete expired tokens (ClearlyClaire)
* Change profile updates to be sent to recently-mentioned servers (ClearlyClaire)
* Change automatic post deletion thresholds and load detection (ClearlyClaire)
[1.11.6]
* Update Mastodon to 4.1.4
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.4)
* Fix branding:generate_app_icons failing because of disallowed ICO coder (ClearlyClaire)
* Fix crash in admin interface when viewing a remote user with verified links (ClearlyClaire)
* Fix processing of media files with unusual names (ClearlyClaire)
[1.11.7]
* Update Mastodon to 4.1.5
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.5)
* Add check preventing Sidekiq workers from running with Makara configured (ClearlyClaire)
* Change request timeout handling to use a longer deadline (ClearlyClaire)
* Fix moderation interface for remote instances with a .zip TLD (ClearlyClaire)
* Fix remote accounts being possibly persisted to database with incomplete protocol values (ClearlyClaire)
* Fix trending publishers table not rendering correctly on narrow screens (vmstan)
* Fix CSP headers being unintentionally wide (ClearlyClaire)
[1.11.8]
* Update Mastodon to 4.1.6
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.6)
* Fix memory leak in streaming server (ThisIsMissEm)
* Fix wrong filters sometimes applying in streaming (ClearlyClaire, ThisIsMissEm, renchap)
* Fix incorrect connect timeout in outgoing requests (ClearlyClaire)
[1.11.9]
* Update Mastodon to 4.1.7
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.7)
* Change remote report processing to accept reports with long comments, but truncate them (ThisIsMissEm)
* Fix blocking subdomains of an already-blocked domain (ClearlyClaire)
* Fix /api/v1/timelines/tag/:hashtag allowing for unauthenticated access when public preview is disabled (danielmbrasil)
* Fix inefficiencies in PlainTextFormatter (ClearlyClaire)
[1.11.10]
* Update Mastodon to 4.1.8
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.8)
* This release is an important security release fixing major security issues (CVE-2023-42451, CVE-2023-42452).
* Fix post edits not being forwarded as expected (ClearlyClaire)
* Fix moderator rights inconsistencies (ClearlyClaire)
* Fix crash when encountering invalid URL (ClearlyClaire)
* Fix cached posts including stale stats (ClearlyClaire)
[1.11.11]
* Update Mastodon to 4.1.9
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.1.9)
* Fix post translation erroring out (ClearlyClaire)
* Fix post edits not being forwarded as expected (ClearlyClaire)
* Fix moderator rights inconsistencies (ClearlyClaire)
* Fix crash when encountering invalid URL (ClearlyClaire)
* Fix cached posts including stale stats (ClearlyClaire)
* Fix uploading of video files for which ffprobe reports 0/0 average framerate (NicolaiSoeborg)
* Fix unexpected audio stream transcoding when uploaded video is eligible to passthrough (yufushiro)
* Fix missing HTML sanitization in translation API (CVE-2023-42452, GHSA-2693-xr3m-jhqr)
* Fix incorrect domain name normalization (CVE-2023-42451, GHSA-v3xf-c9qf-j667)
[1.12.0]
* Update Mastodon to 4.2.0
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.0)
* Add “Privacy and reach” tab in profile settings (Gargron, ClearlyClaire)
* This reorganized scattered privacy and reach settings to a single place, as well as improve their wording.
* Add display of out-of-band hashtags in the web interface (Gargron, arbolitoloco1, ClearlyClaire, ClearlyClaire, ClearlyClaire, Gargron, ClearlyClaire)
* Add role badges to the web interface (ClearlyClaire, Gargron)
* Add ability to pick domains to forward reports to using the forward_to_domains parameter in POST /api/v1/reports (ClearlyClaire, ClearlyClaire)
* The forward_to_domains REST API parameter is a list of strings. If it is empty or omitted, the previous behavior is maintained.
* The forward parameter still needs to be set for forward_to_domains to be taken into account.
* The forwarded-to domains can only include that of the original author and people being replied to.
* Add forwarding of reported replies to servers being replied to (Gargron, ClearlyClaire)
* Add ONE_CLICK_SSO_LOGIN environment variable to directly link to the Single-Sign On provider if there is only one sign up method available (CSDUMMI, ClearlyClaire, CSDUMMI, ClearlyClaire)
* Add webhook templating (Gargron)
* Add webhooks for local status.created, status.updated, account.updated and report.updated (VyrCossont, VyrCossont, VyrCossont)
[1.12.1]
* Update Mastodon to 4.2.1
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.1)
* Add redirection on /deck URLs for logged-out users (ClearlyClaire)
* Add support for v4.2.0 migrations to tootctl maintenance fix-duplicates (ClearlyClaire)
* Change some worker lock TTLs to be shorter-lived (ClearlyClaire)
* Change user archive export allowed period from 7 days to 6 days (suddjian)
[1.12.2]
* Update Mastodon to 4.2.2
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.2)
* Change dismissed banners to be stored server-side (ClearlyClaire)
* Change GIF max matrix size error to explicitly mention GIF files (ClearlyClaire)
* Change Follow activities delivery to bypass availability check (ShadowJonathan)
* Change single-column navigation notice to be displayed outside of the logo container (renchap, renchap)
* Change Content-Security-Policy to be tighter on media paths (ClearlyClaire)
* Change post language code to include country code when relevant (gunchleoc, ClearlyClaire)
* Fix upper border radius of onboarding columns (ClearlyClaire)
* Fix incoming status creation date not being restricted to standard ISO8601 (ClearlyClaire, ClearlyClaire)
* Fix some posts from threads received out-of-order sometimes not being inserted into timelines (ClearlyClaire)
* Fix posts from force-sensitized accounts being able to trend (ClearlyClaire)
* Fix error when trying to delete already-deleted file with OpenStack Swift (ClearlyClaire)
* Fix batch attachment deletion when using OpenStack Swift (ClearlyClaire)
* Fix processing LDSigned activities from actors with unknown public keys (ClearlyClaire)
* Fix error and incorrect URLs in /api/v1/accounts/:id/featured_tags for remote accounts (ClearlyClaire)
* Fix report processing notice not mentioning the report number when performing a custom action (ClearlyClaire)
* Fix handling of inLanguage attribute in preview card processing (ClearlyClaire)
* Fix own posts being removed from home timeline when unfollowing a used hashtag (kmycode)
* Fix some link anchors being recognized as hashtags (ClearlyClaire, ClearlyClaire)
* Fix format-dependent redirects being cached regardless of requested format (ClearlyClaire)
[1.12.3]
* Update Mastodon to 4.2.3
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.3)
* Fix dependency on json-canonicalization version that has been made unavailable since last release
[1.12.4]
* Update Mastodon to 4.2.4
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.4)
* Add rate-limit of TOTP authentication attempts at controller level (ClearlyClaire)
* Fix error when processing remote files with unusually long names (ClearlyClaire)
* Fix processing of compacted single-item JSON-LD collections (ClearlyClaire)
* Retry 401 errors on replies fetching (ShadowJonathan)
* Fix RecordNotUnique errors in LinkCrawlWorker (tribela)
* Fix Mastodon not correctly processing HTTP Signatures with query strings (ClearlyClaire, ClearlyClaire)
[1.12.5]
* Update Mastodon to 4.2.5
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.5)
* Fix insufficient origin validation (CVE-2024-23832, GHSA-3fjr-858r-92rw)
[1.12.6]
* Update Mastodon to 4.2.6
* This release is an important security release fixing several security issue.
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.6)
* Change external authentication behavior to never reattach a new identity to an existing user by default (GHSA-vm39-j3vx-pch3)
* Update the nokogiri dependency (see GHSA-xc9x-jj77-9p9j)
* Disable administrative Doorkeeper routes (ThisIsMissEm)
* Fix ongoing streaming sessions not being invalidated when applications get deleted in some cases (GHSA-7w3c-p9j8-mq3x)
* Update the sidekiq-unique-jobs dependency (see GHSA-cmh9-rx85-xj38)
[1.13.0]
* Update Mastodon to 4.2.7
* This release is an important security release fixing several security issue.
* With this package release, the app moves from LDAP authentication to OpenID Connect
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.7)
* Fix OmniAuth tests and edge cases in error handling (ClearlyClaire, ClearlyClaire)
* Fix new installs by upgrading to the latest release of the nsa gem, instead of a no longer existing commit (mjankowski)
* Fix insufficient checking of remote posts (GHSA-jhrq-qvrm-qr36)
[1.13.1]
* Update Mastodon to 4.2.8
* This update changes registrations to be closed by default.
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.8)
* Add hourly task to automatically require approval for new registrations in the absence of moderators (ClearlyClaire, ClearlyClaire)
* In order to prevent future abandoned Mastodon servers from being used for spam, harassment and other malicious activity, Mastodon will now automatically switch new user registrations to require moderator approval whenever they are left open and no activity (including non-moderation actions from apps) from any logged-in user with permission to access moderation reports has been detected in a full week.
* When this happens, users with the permission to change server settings will receive an email notification.
* This feature is disabled when EMAIL_DOMAIN_ALLOWLIST is used, and can also be disabled with DISABLE_AUTOMATIC_SWITCHING_TO_APPROVED_REGISTRATIONS=true.
* Change registrations to be closed by default on new installations (ClearlyClaire)
* If you are running a server and never changed your registrations mode from the default, updating will automatically close your registrations.
* Simply re-enable them through the administration interface or using tootctl settings registrations open if you want to enable them again.
* Fix processing of remote ActivityPub actors making use of Link objects as Image url (ClearlyClaire)
* Fix link verifications when page size exceeds 1MB (ClearlyClaire)
[1.13.2]
* Update Mastodon to 4.2.9
* [Full changelog](https://github.com/mastodon/mastodon/releases/tag/v4.2.9)
* Update dependencies
* Fix private mention filtering (GHSA-5fq7-3p3j-9vrf)
* Fix password change endpoint not being rate-limited (GHSA-q3rg-xx5v-4mxh)
* Add hardening around rate-limit bypass (GHSA-c2r5-cfqr-c553)

View file

@ -5,8 +5,8 @@
"description": "file://DESCRIPTION.md",
"changelog": "file://CHANGELOG",
"tagline": "Federated social network",
"version": "1.10.0",
"upstreamVersion": "4.0.2",
"version": "1.13.2",
"upstreamVersion": "4.2.9",
"healthCheckPath": "/about",
"httpPort": 8000,
"memoryLimit": 1610612736,
@ -16,10 +16,10 @@
"postgresql": {},
"redis": {},
"sendmail": {},
"ldap": {},
"oidc": { "loginRedirectUri": "/auth/auth/openid_connect/callback" },
"scheduler": {
"cleanup": {
"schedule": "11 11 * * *",
"schedule": "11 01 * * *",
"command": "/app/pkg/cleanup.sh"
}
}

View file

@ -1,4 +1,4 @@
FROM cloudron/base:4.0.0@sha256:31b195ed0662bdb06a6e8a5ddbedb6f191ce92e8bee04c03fb02dd4e9d0286df
FROM cloudron/base:4.2.0@sha256:46da2fffb36353ef714f97ae8e962bd2c212ca091108d768ba473078319a47f4
RUN mkdir -p /app/code /app/pkg
WORKDIR /app/code
@ -17,30 +17,31 @@ RUN apt-get update && \
libidn11-dev libicu-dev libjemalloc-dev && \
rm -rf /var/cache/apt /var/lib/apt/lists
# install rbenv since we need ruby 3.0.4
# install rbenv since we need ruby 3.2.3
RUN mkdir -p /usr/local/rbenv && curl -LSs "https://github.com/rbenv/rbenv/archive/refs/tags/v1.2.0.tar.gz" | tar -xz -C /usr/local/rbenv --strip-components 1 -f -
ENV PATH /usr/local/rbenv/bin:$PATH
RUN mkdir -p "$(rbenv root)"/plugins/ruby-build && curl -LSs "https://github.com/rbenv/ruby-build/archive/refs/tags/v20221101.tar.gz" | tar -xz -C "$(rbenv root)"/plugins/ruby-build --strip-components 1 -f -
ENV RBENV_ROOT /home/cloudron/rbenv
RUN mkdir -p "$(rbenv root)"/plugins/ruby-build && curl -LSs "https://github.com/rbenv/ruby-build/archive/refs/tags/v20240530.1.tar.gz" | tar -xz -C "$(rbenv root)"/plugins/ruby-build --strip-components 1 -f -
# install specific ruby version (https://github.com/mastodon/mastodon/blob/main/Dockerfile)
ARG RUBY_VERSION=3.0.4
ARG RUBY_VERSION=3.2.3
RUN rbenv install ${RUBY_VERSION}
# this allows cloudron user to access ruby
RUN chmod o+rx /root
ENV PATH /root/.rbenv/versions/${RUBY_VERSION}/bin:$PATH
ENV PATH ${RBENV_ROOT}/versions/${RUBY_VERSION}/bin:$PATH
RUN gem install --no-document bundler
ENV RAILS_ENV production
ENV NODE_ENV production
ARG VERSION=4.0.2
ARG VERSION=4.2.9
RUN curl -L https://github.com/tootsuite/mastodon/archive/v${VERSION}.tar.gz | tar -xz --strip-components 1 -f - && \
bundle config --local set deployment 'true' && \
bundle config --local set without 'development test' && \
bundle config --local set silence_root_warning true && \
bundle install && \
bundle clean --force && \
rm -rf ~/.bundle /usr/local/bundle/cache && \
yarn install --pure-lockfile
# secret keys are not built into assets, so precompiling is safe to do here
@ -68,7 +69,7 @@ RUN ln -sf /run/mastodon/supervisord.log /var/log/supervisor/supervisord.log
RUN ln -fs /app/data/env.production /app/code/.env.production
RUN ln -fs /app/data/system /app/code/public/system
COPY start.sh cleanup.sh config.sh env.template /app/pkg/
COPY start.sh cleanup.sh config.sh env.template cache-env.sh.template /app/pkg/
CMD [ "/app/pkg/start.sh" ]

View file

@ -1,4 +1,6 @@
Accounts are created with the username and the subdomain under which this app is installed e.g. `@$CLOUDRON-USERNAME@$CLOUDRON-APP-FQDN`. Mastodon does not allow changing the domain part of the account later. See [the docs](https://docs.cloudron.io/apps/mastodon/#federation) for more information, if you want to change this domain.
Accounts are created with the username and the subdomain under which this app is installed e.g. `@$CLOUDRON-USERNAME@$CLOUDRON-APP-FQDN`.
Mastodon does not allow changing the domain part of the account later.
See [the docs](https://docs.cloudron.io/apps/mastodon/#federation) for more information, f you want to change this domain.
<sso>
**NOTE:**
@ -7,3 +9,9 @@ Accounts are created with the username and the subdomain under which this app is
* External registration [does not work well](https://github.com/mastodon/mastodon/issues/20655) when Cloudron user management is enabled.
</sso>
<nosso>
**NOTE:**
* Open registration is disabled by default. To enable this, see the [docs](https://docs.cloudron.io/apps/mastodon/#registration)
* To add an initial account follow those [instructions](https://docs.cloudron.io/apps/mastodon/#adding-users)
</nosso>

4
cache-env.sh.template Normal file
View file

@ -0,0 +1,4 @@
#!/bin/bash
# number of days to keep cache
export CACHE_RETENTION_DAYS=2

View file

@ -5,11 +5,35 @@ set -eu
echo "=> Cleanup"
cd /app/code
if [[ ! -f /app/data/cache-env.sh ]]; then
echo "==> Creating initial cache-env.sh"
cp /app/pkg/cache-env.sh.template /app/data/cache-env.sh
fi
source /app/data/cache-env.sh
echo "=> Retention days set to ${CACHE_RETENTION_DAYS}"
echo "==> media cache ..."
./bin/tootctl media remove --days=7
./bin/tootctl media remove --days=${CACHE_RETENTION_DAYS}
echo "==> orphaned media ..."
./bin/tootctl media remove-orphans
echo "==> preview cards.."
./bin/tootctl preview-cards remove --days=7
echo "==> preview cards ..."
./bin/tootctl preview-cards remove --days=${CACHE_RETENTION_DAYS}
echo "==> prune profiles ..."
./bin/tootctl media remove --prune-profiles --days=${CACHE_RETENTION_DAYS}
echo "==> remove headers ..."
./bin/tootctl media remove --remove-headers --days=${CACHE_RETENTION_DAYS}
echo "==> clear cache ..."
/app/code/bin/tootctl cache clear
echo "==> remove unreferenced statuses ..."
/app/code/bin/tootctl statuses remove --days=${CACHE_RETENTION_DAYS}
echo "==> prune accounts ..."
/app/code/bin/tootctl accounts prune

View file

@ -32,20 +32,22 @@ SMTP_AUTH_METHOD=plain
SMTP_OPENSSL_VERIFY_MODE=none
# SSO configuration
LDAP_ENABLED=
LDAP_HOST=
LDAP_PORT=
LDAP_BASE=
LDAP_BIND_DN=
LDAP_PASSWORD=
LDAP_UID=username
LDAP_SEARCH_FILTER=(|(%{uid}=%{email})(mail=%{email}))
LDAP_METHOD=plain
OIDC_ENABLED=
OIDC_DISPLAY_NAME=
OIDC_ISSUER=
OIDC_CLIENT_ID=
OIDC_CLIENT_SECRET=
OIDC_REDIRECT_URI=
OIDC_DISCOVERY=
OIDC_SCOPE=
OIDC_UID_FIELD=
# Application secrets
SECRET_KEY_BASE=
OTP_SECRET=
UPDATE_CHECK_URL=
# Optionally change default language
# DEFAULT_LOCALE=de

View file

@ -1,8 +1,18 @@
# derived from https://github.com/mastodon/mastodon/blob/main/dist/nginx.conf
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
upstream backend {
server 127.0.0.1:3000 fail_timeout=0;
}
upstream streaming {
server 127.0.0.1:4000 fail_timeout=0;
}
proxy_cache_path /run/nginx/cache levels=1:2 keys_zone=CACHE:10m inactive=7d max_size=1g;
server {
@ -11,7 +21,7 @@ server {
keepalive_timeout 70;
sendfile on;
client_max_body_size 80m;
client_max_body_size 99m;
root /app/code/public;
@ -22,40 +32,96 @@ server {
gzip_comp_level 6;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
add_header Strict-Transport-Security "max-age=31536000";
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript image/svg+xml image/x-icon;
location / {
try_files $uri @proxy;
}
location ~ ^/(emoji|packs|system/accounts/avatars|system/media_attachments/files) {
add_header Cache-Control "public, max-age=31536000, immutable";
add_header Strict-Transport-Security "max-age=31536000";
try_files $uri @proxy;
location = /sw.js {
add_header Cache-Control "public, max-age=604800, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location /sw.js {
add_header Cache-Control "public, max-age=0";
add_header Strict-Transport-Security "max-age=31536000";
try_files $uri @proxy;
location ~ ^/assets/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/avatars/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/emoji/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/headers/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/packs/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/shortcuts/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/sounds/ {
add_header Cache-Control "public, max-age=2419200, must-revalidate";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
try_files $uri =404;
}
location ~ ^/system/ {
add_header Cache-Control "public, max-age=2419200, immutable";
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
add_header X-Content-Type-Options nosniff;
add_header Content-Security-Policy "default-src 'none'; form-action 'none'";
try_files $uri =404;
}
location ^~ /api/v1/streaming {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $http_x_real_ip;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header Proxy "";
proxy_pass http://streaming;
proxy_buffering off;
proxy_redirect off;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
tcp_nodelay on;
}
location @proxy {
# forwarding cloudron's nginx proxy-proto headers
proxy_set_header Host $host;
proxy_set_header X-Real-IP $http_x_real_ip;
proxy_set_header X-Forwarded-For $http_x_forwarded_for,$remote_addr;
proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto;
proxy_set_header X-Forwarded-Host $http_x_forwarded_host;
proxy_set_header X-Forwarded-Port $http_x_forwarded_port;
proxy_set_header X-Forwarded-Server $http_x_forwarded_server;
proxy_set_header Proxy "";
proxy_pass_header Server;
proxy_pass http://127.0.0.1:3000;
proxy_pass http://backend;
proxy_buffering on;
proxy_redirect off;
proxy_http_version 1.1;
@ -64,29 +130,12 @@ server {
proxy_cache CACHE;
proxy_cache_valid 200 7d;
proxy_cache_valid 410 24h;
proxy_cache_use_stale error timeout updating http_500 http_502 http_503 http_504;
add_header X-Cached $upstream_cache_status;
add_header Strict-Transport-Security "max-age=31536000";
tcp_nodelay on;
}
location /api/v1/streaming {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header Proxy "";
proxy_pass http://127.0.0.1:4000;
proxy_buffering off;
proxy_redirect off;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
tcp_nodelay on;
}
error_page 500 501 502 503 504 /500.html;
error_page 404 500 501 502 503 504 /500.html;
}

View file

@ -30,16 +30,19 @@ sed -e "s/DB_HOST=.*/DB_HOST=${CLOUDRON_POSTGRESQL_HOST}/g" \
-e "s/WEB_DOMAIN=.*/WEB_DOMAIN=${CLOUDRON_APP_DOMAIN}/g" \
-i /app/data/env.production
if [[ -n "${CLOUDRON_LDAP_SERVER:-}" ]]; then
sed -e "s/LDAP_ENABLED=.*/LDAP_ENABLED=true/g" \
-e "s/LDAP_HOST=.*/LDAP_HOST=${CLOUDRON_LDAP_SERVER}/g" \
-e "s/LDAP_PORT=.*/LDAP_PORT=${CLOUDRON_LDAP_PORT}/g" \
-e "s/LDAP_BASE=.*/LDAP_BASE=${CLOUDRON_LDAP_USERS_BASE_DN}/g" \
-e "s/LDAP_BIND_DN=.*/LDAP_BIND_DN=${CLOUDRON_LDAP_BIND_DN}/g" \
-e "s/LDAP_BIND_PASSWORD=.*/LDAP_BIND_PASSWORD=${CLOUDRON_LDAP_BIND_PASSWORD}/g" \
if [[ -n "${CLOUDRON_OIDC_ISSUER:-}" ]]; then
echo "==> Setting up OIDC"
sed -e "s/OIDC_ENABLED=.*/OIDC_ENABLED=true/g" \
-e "s/OIDC_DISPLAY_NAME=.*/OIDC_DISPLAY_NAME=Cloudron/g" \
-e "s/OIDC_ISSUER=.*/OIDC_ISSUER=${CLOUDRON_OIDC_ISSUER//\//\\\/}/g" \
-e "s/OIDC_CLIENT_ID=.*/OIDC_CLIENT_ID=${CLOUDRON_OIDC_CLIENT_ID}/g" \
-e "s/OIDC_CLIENT_SECRET=.*/OIDC_CLIENT_SECRET=${CLOUDRON_OIDC_CLIENT_SECRET}/g" \
-e "s/OIDC_REDIRECT_URI=.*/OIDC_REDIRECT_URI=${CLOUDRON_APP_ORIGIN//\//\\\/}\/auth\/auth\/openid_connect\/callback/g" \
-e "s/OIDC_DISCOVERY=.*/OIDC_DISCOVERY=true/g" \
-e "s/OIDC_SCOPE=.*/OIDC_SCOPE=openid,profile,email/g" \
-e "s/OIDC_UID_FIELD=.*/OIDC_UID_FIELD=sub/g" \
-e "s/OIDC_SECURITY_ASSUME_EMAIL_IS_VERIFIED=.*/OIDC_SECURITY_ASSUME_EMAIL_IS_VERIFIED=true/g" \
-i /app/data/env.production
else
sed -e "s/LDAP_ENABLED=.*/LDAP_ENABLED=false/g" -i /app/data/env.production
fi
rm -f /run/mastodon/Gemfile.lock && cp /app/code/Gemfile.lock.original /run/mastodon/Gemfile.lock
@ -57,7 +60,7 @@ if grep -q "^SECRET_KEY_BASE=$" /app/data/env.production; then
echo "==> Init database"
HOME=/app/data SAFETY_ASSURED=1 bundle exec rails db:schema:load db:seed
if [[ -n "${CLOUDRON_LDAP_SERVER:-}" ]]; then
if [[ -n "${CLOUDRON_OIDC_ISSUER:-}" ]]; then
echo "Disabling registration by default"
PGPASSWORD=${CLOUDRON_POSTGRESQL_PASSWORD} psql -h ${CLOUDRON_POSTGRESQL_HOST} -p ${CLOUDRON_POSTGRESQL_PORT} -U ${CLOUDRON_POSTGRESQL_USERNAME} -d ${CLOUDRON_POSTGRESQL_DATABASE} \
-c "INSERT INTO settings (var, value) VALUES ('registrations_mode', 'none')"
@ -67,6 +70,10 @@ else
HOME=/app/data SAFETY_ASSURED=1 bundle exec rails db:migrate
fi
if ! grep -q UPDATE_CHECK_URL /app/data/env.production; then
echo -e "\nUPDATE_CHECK_URL=" >> /app/data/env.production
fi
chown -R cloudron:cloudron /tmp/mastodon /run/mastodon
if [[ "$(stat -c '%U' /app/data)" != "cloudron" ]]; then

870
test/package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -10,10 +10,10 @@
"license": "ISC",
"devDependencies": {
"expect.js": "^0.3.1",
"mocha": "^10.2.0",
"selenium-webdriver": "^4.7.1"
"mocha": "^10.4.0",
"selenium-webdriver": "^4.21.0"
},
"dependencies": {
"chromedriver": "^108.0.0"
"chromedriver": "^125.0.2"
}
}

View file

@ -30,6 +30,7 @@ describe('Application life cycle test', function () {
const EXEC_ARGS = { cwd: path.resolve(__dirname, '..'), stdio: 'inherit' };
let browser, app;
var athenticated_by_oidc = false;
let username = process.env.USERNAME;
let password = process.env.PASSWORD;
let manifest = require('../CloudronManifest.json');
@ -42,6 +43,15 @@ describe('Application life cycle test', function () {
browser.quit();
});
function sleep(millis) {
return new Promise(resolve => setTimeout(resolve, millis));
}
async function waitForElement(elem) {
await browser.wait(until.elementLocated(elem), TEST_TIMEOUT);
await browser.wait(until.elementIsVisible(browser.findElement(elem)), TEST_TIMEOUT);
}
async function exists(selector) {
await browser.wait(until.elementLocated(selector), TEST_TIMEOUT);
}
@ -52,10 +62,10 @@ describe('Application life cycle test', function () {
}
async function checkRegistration(mode) {
if (mode === 'none') {
if (mode === 'none') {
await browser.get('https://' + app.fqdn);
await browser.sleep(2000);
await browser.findElement(By.xpath('//button/span[contains(text(), "Create account")]')).click();
await browser.findElement(By.xpath('//div[@class="sign-in-banner"]/descendant::button/span[contains(text(), "Create account")] | //div[@class="sign-in-banner"]/descendant::a/span[contains(text(), "Create account")]')).click();
await visible(By.xpath('//span[contains(text()[2], "is currently not possible")]'));
} else if (mode === 'open') {
await browser.get('https://' + app.fqdn + '/auth/sign_up');
@ -65,85 +75,66 @@ describe('Application life cycle test', function () {
async function login(username, password) {
await browser.get('https://' + app.fqdn + '/auth/sign_in'); // there is also separate login page at /users/sign_in
await browser.wait(until.elementLocated(By.xpath('//button[contains(text(), "Log in")]')), TEST_TIMEOUT);
await visible(By.xpath('//button[contains(text(), "Log in")]'));
await browser.findElement(By.id('user_email')).sendKeys(username);
await browser.findElement(By.id('user_password')).sendKeys(password);
await browser.findElement(By.xpath('//button[contains(text(), "Log in")]')).click();
await browser.sleep(3000); // can be wizard or timeline at this point
}
async function loginOIDC(username, password) {
browser.manage().deleteAllCookies();
await browser.get(`https://${app.fqdn}/auth/sign_in`);
await browser.sleep(4000);
await browser.findElement(By.xpath('//a[contains(@class, "button") and text()="Cloudron"]')).click();
await browser.sleep(4000);
if (!athenticated_by_oidc) {
await waitForElement(By.xpath('//input[@name="username"]'));
await browser.findElement(By.xpath('//input[@name="username"]')).sendKeys(username);
await browser.findElement(By.xpath('//input[@name="password"]')).sendKeys(password);
await browser.sleep(2000);
await browser.findElement(By.id('loginSubmitButton')).click();
await browser.sleep(2000);
athenticated_by_oidc = true;
}
await waitForElement(By.xpath('//a[contains(., "Edit profile")] | //strong[text()="Successfully authenticated from Cloudron account."]'));
}
async function logout() {
await browser.get('https://' + app.fqdn + '/settings/preferences/appearance'); // there is also separate login page at /users/sign_in
await browser.wait(until.elementLocated(By.id('logout')), TEST_TIMEOUT);
await browser.findElement(By.id('logout')).click();
await browser.wait(until.elementLocated(By.id('user_email')), TEST_TIMEOUT);
await visible(By.id('user_email'));
}
async function skipTutorial() {
await browser.get('https://' + app.fqdn + '/web/start');
await browser.wait(until.elementLocated(By.xpath('//button/span[text() = "Done"]')), TEST_TIMEOUT);
await browser.findElement(By.xpath('//button/span[text() = "Done"]')).click();
await browser.sleep(5000); // can be wizard or timeline at this point
await browser.wait(until.elementLocated(By.xpath('//span[text() = "See some suggestions"]')), TEST_TIMEOUT);
await browser.sleep(5000);
async function dismissHelp() {
await browser.get('https://' + app.fqdn + '/home');
await visible(By.xpath('//button[@title = "Dismiss"]'));
await browser.findElement(By.xpath('//button[@title ="Dismiss"]')).click();
}
async function checkTimeline() {
await browser.get('https://' + app.fqdn + '/home');
await browser.sleep(2000);
await browser.wait(until.elementLocated(By.xpath('//span[text() = "See some suggestions"]')), TEST_TIMEOUT);
await visible(By.xpath('//span[contains(text(), "Your home timeline is empty")]'));
}
function getAppInfo() {
var inspect = JSON.parse(execSync('cloudron inspect'));
const inspect = JSON.parse(execSync('cloudron inspect'));
app = inspect.apps.filter(function (a) { return a.location === LOCATION || a.location === LOCATION + '2'; })[0];
expect(app).to.be.an('object');
}
xit('build app', function () { execSync('cloudron build', EXEC_ARGS); });
it('install app', function () { execSync('cloudron install --location ' + LOCATION, EXEC_ARGS); });
it('can get app information', getAppInfo);
it('registration is disabled', checkRegistration.bind(null, 'none'));
it('can LDAP login', login.bind(null, username, password));
it('can skip tutorial', skipTutorial);
it('can see timeline', checkTimeline);
it('can logout', logout);
it('backup app', function () { execSync('cloudron backup create --app ' + app.id, EXEC_ARGS); });
it('restore app', function () {
const backups = JSON.parse(execSync('cloudron backup list --raw'));
execSync('cloudron uninstall --app ' + app.id, EXEC_ARGS);
execSync('cloudron install --location ' + LOCATION, EXEC_ARGS);
getAppInfo();
execSync(`cloudron restore --backup ${backups[0].id} --app ${app.id}`, EXEC_ARGS);
});
it('can LDAP login', login.bind(null, username, password));
it('can see timeline', checkTimeline);
it('can restart app', function () { execSync('cloudron restart --app ' + app.id, EXEC_ARGS); });
it('can see timeline', checkTimeline);
it('move to different location', async function () {
await browser.get('about:blank');
execSync('cloudron configure --location ' + LOCATION + '2 --app ' + app.id, EXEC_ARGS);
});
it('can get app information', getAppInfo);
it('can LDAP login', login.bind(null, username, password));
it('can see timeline', checkTimeline);
it('uninstall app', async function () {
await browser.get('about:blank');
execSync('cloudron uninstall --app ' + app.id, EXEC_ARGS);
});
// No SSO
it('install app (no sso)', function () { execSync('cloudron install --no-sso --location ' + LOCATION, EXEC_ARGS); });
it('can get app information', getAppInfo);
it('has registration open', checkRegistration.bind(null, 'open'));
it('has registration open', checkRegistration.bind(null, 'none'));
let testPassword;
it('create a user with CLI', function () {
let output = execSync('cloudron exec --app ' + LOCATION + ' -- bin/tootctl accounts create test --email=test@cloudron.io', { cwd: path.resolve(__dirname, '..'), encoding: 'utf8' });
@ -165,10 +156,50 @@ describe('Application life cycle test', function () {
execSync('cloudron uninstall --app ' + app.id, EXEC_ARGS);
});
// SSO
it('install app (sso)', function () { execSync('cloudron install --location ' + LOCATION, EXEC_ARGS); });
it('can get app information', getAppInfo);
it('registration is disabled', checkRegistration.bind(null, 'none'));
it('can OIDC login', loginOIDC.bind(null, username, password));
it('can dismiss help', dismissHelp);
it('can see timeline', checkTimeline);
it('can logout', logout);
it('backup app', function () { execSync('cloudron backup create --app ' + app.id, EXEC_ARGS); });
it('restore app', function () {
const backups = JSON.parse(execSync('cloudron backup list --raw'));
execSync('cloudron uninstall --app ' + app.id, EXEC_ARGS);
execSync('cloudron install --location ' + LOCATION, EXEC_ARGS);
getAppInfo();
execSync(`cloudron restore --backup ${backups[0].id} --app ${app.id}`, EXEC_ARGS);
});
it('can OIDC login', loginOIDC.bind(null, username, password));
it('can see timeline', checkTimeline);
it('can restart app', function () { execSync('cloudron restart --app ' + app.id, EXEC_ARGS); });
it('can see timeline', checkTimeline);
it('move to different location', async function () {
await browser.get('about:blank');
execSync('cloudron configure --location ' + LOCATION + '2 --app ' + app.id, EXEC_ARGS);
});
it('can get app information', getAppInfo);
it('can OIDC login', loginOIDC.bind(null, username, password));
it('can see timeline', checkTimeline);
it('uninstall app', async function () {
await browser.get('about:blank');
execSync('cloudron uninstall --app ' + app.id, EXEC_ARGS);
});
// test update
it('can install app', function () { execSync('cloudron install --appstore-id ' + manifest.id + ' --location ' + LOCATION, EXEC_ARGS); });
it('can get app information', getAppInfo);
it('can LDAP login', login.bind(null, username, password));
// needs to be changed to loginOIDC on the next release
it('can OIDC login', loginOIDC.bind(null, username, password));
it('can logout', logout);
it('can update', async function () {
@ -176,7 +207,7 @@ describe('Application life cycle test', function () {
execSync('cloudron update --app ' + LOCATION, EXEC_ARGS);
});
it('can LDAP login', login.bind(null, username, password));
it('can OIDC login', loginOIDC.bind(null, username, password));
it('uninstall app', function () { execSync('cloudron uninstall --app ' + app.id, EXEC_ARGS); });
});