Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
freedombone
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Context Sensitive Group
freedombone
Commits
4976d89b
Commit
4976d89b
authored
6 years ago
by
Bob Mottram
Browse files
Options
Downloads
Patches
Plain Diff
Updating riot homeserver
parent
b1be275b
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/freedombone-app-matrix
+1
-8
1 addition, 8 deletions
src/freedombone-app-matrix
src/freedombone-app-riot
+11
-0
11 additions, 0 deletions
src/freedombone-app-riot
with
12 additions
and
8 deletions
src/freedombone-app-matrix
+
1
−
8
View file @
4976d89b
...
...
@@ -882,14 +882,7 @@ function matrix_update_riot_config {
if
[
!
-d
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs"
]
;
then
return
fi
if
[
-f
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$RIOT_DOMAIN_NAME
.json"
]
;
then
sed
-i
"s|
\"
default_hs_url
\"
:.*|
\"
default_hs_url
\"
:
\"
https://
${
RIOT_DOMAIN_NAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$RIOT_DOMAIN_NAME
.json"
sed
-i
"s|
\"
default_is_url
\"
:.*|
\"
default_is_url
\"
:
\"
https://
${
RIOT_DOMAIN_NAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$RIOT_DOMAIN_NAME
.json"
fi
if
[
-f
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$MATRIX_ONION_HOSTNAME
.json"
]
;
then
sed
-i
"s|
\"
default_hs_url
\"
:.*|
\"
default_hs_url
\"
:
\"
https://
${
MATRIX_ONION_HOSTNAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$MATRIX_ONION_HOSTNAME
.json"
sed
-i
"s|
\"
default_is_url
\"
:.*|
\"
default_is_url
\"
:
\"
https://
${
MATRIX_ONION_HOSTNAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$MATRIX_ONION_HOSTNAME
.json"
fi
riot_set_default_homeserver
}
function
install_matrix
{
...
...
This diff is collapsed.
Click to expand it.
src/freedombone-app-riot
+
11
−
0
View file @
4976d89b
...
...
@@ -62,9 +62,20 @@ function riot_set_default_homeserver {
if
[
!
"
$MATRIX_DOMAIN_NAME
"
]
;
then
read_config_param MATRIX_DOMAIN_NAME
fi
if
[
-f
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$RIOT_DOMAIN_NAME
.json"
]
;
then
sed
-i
"s|
\"
default_hs_url
\"
:.*|
\"
default_hs_url
\"
:
\"
https://
${
RIOT_DOMAIN_NAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$RIOT_DOMAIN_NAME
.json"
sed
-i
"s|
\"
default_is_url
\"
:.*|
\"
default_is_url
\"
:
\"
https://
${
RIOT_DOMAIN_NAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$RIOT_DOMAIN_NAME
.json"
fi
sed
-i
"s|https://matrix.org|https://
$MATRIX_DOMAIN_NAME
|g"
/var/www/
$RIOT_DOMAIN_NAME
/htdocs/bundles/
*
/
*
.js
sed
-i
"s|https://vector.im|https://
$MATRIX_DOMAIN_NAME
|g"
/var/www/
$RIOT_DOMAIN_NAME
/htdocs/bundles/
*
/
*
.js
else
if
[
-f
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$MATRIX_ONION_HOSTNAME
.json"
]
;
then
sed
-i
"s|
\"
default_hs_url
\"
:.*|
\"
default_hs_url
\"
:
\"
https://
${
MATRIX_ONION_HOSTNAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$MATRIX_ONION_HOSTNAME
.json"
sed
-i
"s|
\"
default_is_url
\"
:.*|
\"
default_is_url
\"
:
\"
https://
${
MATRIX_ONION_HOSTNAME
}
\"
,|g"
"/var/www/
$RIOT_DOMAIN_NAME
/htdocs/config.
$MATRIX_ONION_HOSTNAME
.json"
fi
if
[
-f
/var/lib/tor/hidden_service_matrix/hostname
]
;
then
MATRIX_ONION_HOSTNAME
=
$(
cat
/var/lib/tor/hidden_service_matrix/hostname
)
sed
-i
"s|https://matrix.org|http://
$MATRIX_ONION_HOSTNAME
|g"
/var/www/
$RIOT_DOMAIN_NAME
/htdocs/bundles/
*
/
*
.js
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment