Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
B
bash-install
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
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
witchy
bash-install
Commits
e8fb18ec
Commit
e8fb18ec
authored
3 years ago
by
tamaina
Browse files
Options
Downloads
Patches
Plain Diff
wip
parent
0b73a89e
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
ubuntu.sh
+1
-1
1 addition, 1 deletion
ubuntu.sh
update.ubuntu.sh
+22
-5
22 additions, 5 deletions
update.ubuntu.sh
with
23 additions
and
6 deletions
ubuntu.sh
+
1
−
1
View file @
e8fb18ec
...
...
@@ -361,7 +361,7 @@ tput setaf 3;
echo
"Process: apt install #1;"
;
tput setaf 7
;
apt update
-y
;
apt
install
-y
curl nano gnupg2 apt-transport-https ca-certificates lsb-release
git build-essential
software-properties-common
ffmpeg
uidmap
$(
$nginx_local
&&
echo
" certbot"
)$(
$cloudflare
&&
echo
" python3-certbot-dns-cloudflare"
)
;
apt
install
-y
curl nano
jq
gnupg2 apt-transport-https ca-certificates lsb-release software-properties-common uidmap
$(
$nginx_local
&&
echo
" certbot"
)$(
$cloudflare
&&
echo
" python3-certbot-dns-cloudflare"
)
$(
[
$method
!=
"docker_hub"
]
&&
echo
" git"
)$(
[
$method
==
"systemd"
]
&&
" ffmpeg build-essential"
)
;
if
[
$method
!=
"docker_hub"
]
;
then
#region work with misskey user
...
...
This diff is collapsed.
Click to expand it.
update.ubuntu.sh
+
22
−
5
View file @
e8fb18ec
...
...
@@ -40,6 +40,7 @@ if [ -f "/root/.misskey.env" ]; then
method
=
systemd
;
elif
[
-f
"/home/
$misskey_user
/.misskey-docker.env"
]
;
then
.
"/home/
$misskey_user
/.misskey-docker.env"
;
else
misskey_user
=
misskey
;
misskey_directory
=
misskey
;
...
...
@@ -58,7 +59,7 @@ fi
echo
"method:
$method
/ user:
$misskey_user
/ dir:
$misskey_directory
/
$misskey_localhost
:
$misskey_port
"
if
[
$method
==
"systemd"
]
;
then
#region systemd
#region work with misskey user
su
$misskey_user
<<
MKEOF
set -eu;
...
...
@@ -87,9 +88,25 @@ if [ $# == 1 ] && [ $1 == "-r" ]; then
else
systemctl start misskey
;
fi
elif
[
$method
==
"docker"
]
;
then
echo
"todo"
#endregion
else
echo
"todo"
oldid
=
$(
sudo
docker images
--no-trunc
--format
"{{.ID}}"
$docker_repository
)
if
[
$method
==
"docker"
]
;
then
if
[
$#
==
1
]
;
then
docker_repository
=
"
$1
"
;
else
docker_repository
=
"local/misskey:latest"
;
fi
else
if
[
$#
==
1
]
;
then
docker_repository
=
"
$1
"
;
else
docker_repository
=
"misskey/misskey:latest"
;
fi
fi
docker_container
=
$(
sudo
-u
"
$misskey_user
"
XDG_RUNTIME_DIR
=
/run/user/
$m_uid
DOCKER_HOST
=
unix:///run/user/
$m_uid
/docker.sock docker run
-d
-p
$misskey_port
:
$misskey_port
--add-host
=
$misskey_localhost
:
$docker_host_ip
-v
/home/
$misskey_user
/
$misskey_directory
/files:/misskey/files
-v
"/home/
$misskey_user
/
$misskey_directory
/.config/default.yml"
:/misskey/.config/default.yml:ro
--restart
unless-stopped
-t
"
$docker_repository
"
)
;
sudo
docker image
rm local
/misskey:latest
fi
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