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
f1086d88
Commit
f1086d88
authored
3 years ago
by
tamaina
Browse files
Options
Downloads
Patches
Plain Diff
✌️
parent
6b646f03
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGELOG.md
+2
-1
2 additions, 1 deletion
CHANGELOG.md
ubuntu.sh
+33
-32
33 additions, 32 deletions
ubuntu.sh
with
35 additions
and
33 deletions
CHANGELOG.md
+
2
−
1
View file @
f1086d88
## v1.0.0
## v1.0.0
-
MisskeyのDockerでの実行に対応。
-
MisskeyのDockerでの実行に対応。
-
redisの設定が反映されていないのを修正。
-
一部設定が反映されていないのを修正。
*
redisのホスト・ポートとかいろいろ
-
/etc/fstabのswap設定が間違っていたのを修正(/swapfile→/swap)
-
/etc/fstabのswap設定が間違っていたのを修正(/swapfile→/swap)
## v0.2.0
## v0.2.0
...
...
This diff is collapsed.
Click to expand it.
ubuntu.sh
+
33
−
32
View file @
f1086d88
...
@@ -469,19 +469,20 @@ if [ $method != "systemd" ]; then
...
@@ -469,19 +469,20 @@ if [ $method != "systemd" ]; then
systemctl disable
--now
docker.service docker.socket
systemctl disable
--now
docker.service docker.socket
loginctl enable-linger
"
$misskey_user
"
loginctl enable-linger
"
$misskey_user
"
su
"
$misskey_user
"
<<
MKEOF
set -eu;
cd ~;
export XDG_RUNTIME_DIR=/run/user/
\$
UID
dockerd-rootless-setuptool.sh install
export DOCKER_HOST=unix://
\$
XDG_RUNTIME_DIR/docker.sock
su
"
$misskey_user
"
<<-
MKEOF
set -eu;
cd ~;
export XDG_RUNTIME_DIR=/run/user/
\$
UID
dockerd-rootless-setuptool.sh install
tput setaf 2;
export DOCKER_HOST=unix://
\$
XDG_RUNTIME_DIR/docker.sock
echo "Check: docker setup;";
tput setaf 7;
tput setaf 2;
docker ps
echo "Check: docker setup;";
MKEOF
tput setaf 7;
docker ps
MKEOF
#endregion
#endregion
#region modify postgres confs
#region modify postgres confs
...
@@ -517,10 +518,10 @@ MKEOF
...
@@ -517,10 +518,10 @@ MKEOF
if
[
-f
/etc/redis/redis.conf
]
;
then
if
[
-f
/etc/redis/redis.conf
]
;
then
sed
-i
'.mkmoded'
-e
"s/
$pgconf_search
/listen_addresses = '
$docker_host_ip
' /g"
"
$pg_conf
"
;
sed
-i
'.mkmoded'
-e
"s/
$pgconf_search
/listen_addresses = '
$docker_host_ip
' /g"
"
$pg_conf
"
;
cat
>
/etc/redis/docker.conf
<<
_EOF
cat
>
/etc/redis/docker.conf
<<
-
_EOF
bind
$docker_host_ip
bind
$docker_host_ip
requirepass
$redis_pass
requirepass
$redis_pass
_EOF
_EOF
if
!
grep
"include /etc/redis/docker.conf"
/etc/redis/redis.conf
;
then
if
!
grep
"include /etc/redis/docker.conf"
/etc/redis/redis.conf
;
then
echo
"include /etc/redis/docker.conf"
>>
/etc/redis/redis.conf
;
echo
"include /etc/redis/docker.conf"
>>
/etc/redis/redis.conf
;
fi
fi
...
@@ -544,14 +545,14 @@ cd ~;
...
@@ -544,14 +545,14 @@ cd ~;
tput setaf 3;
tput setaf 3;
echo "Process: git clone;";
echo "Process: git clone;";
tput setaf 7;
tput setaf 7;
if [ -e ./
$misskey_directory
]; then
if [ -e
"
./
$misskey_directory
"
]; then
if [ -f ./
$misskey_directory
]; then
if [ -f
"
./
$misskey_directory
"
]; then
rm ./
$misskey_directory
;
rm
"
./
$misskey_directory
"
;
else
else
rm -rf ./
$misskey_directory
;
rm -rf
"
./
$misskey_directory
"
;
fi
fi
fi
fi
git clone -b "
$branch
" --depth 1 "
$repository
"
$misskey_directory
;
git clone -b "
$branch
" --depth 1 "
$repository
"
"
$misskey_directory
"
;
MKEOF
MKEOF
else
else
...
@@ -559,19 +560,19 @@ else
...
@@ -559,19 +560,19 @@ else
su
"
$misskey_user
"
<<
MKEOF
su
"
$misskey_user
"
<<
MKEOF
set -eu;
set -eu;
cd ~;
cd ~;
if [ -e ./
$misskey_directory
]; then
if [ -e
"
./
$misskey_directory
"
]; then
if [ -f ./
$misskey_directory
]; then
if [ -f
"
./
$misskey_directory
"
]; then
rm ./
$misskey_directory
;
rm
"
./
$misskey_directory
"
;
fi
fi
else
else
mkdir ./
$misskey_directory
mkdir
"
./
$misskey_directory
"
fi
fi
if [ -e ./
$misskey_directory
/.config ]; then
if [ -e
"
./
$misskey_directory
/.config
"
]; then
if [ -f ./
$misskey_directory
/.config ]; then
if [ -f
"
./
$misskey_directory
/.config
"
]; then
rm ./
$misskey_directory
/.config;
rm
"
./
$misskey_directory
/.config
"
;
fi
fi
else
else
mkdir ./
$misskey_directory
/.config
mkdir
"
./
$misskey_directory
/.config
"
fi
fi
MKEOF
MKEOF
fi
fi
...
@@ -583,7 +584,7 @@ su "$misskey_user" << MKEOF
...
@@ -583,7 +584,7 @@ su "$misskey_user" << MKEOF
set -eu;
set -eu;
cd ~;
cd ~;
cat >
$misskey_directory
/.config/default.yml << _EOF
cat >
"
$misskey_directory
/.config/default.yml
"
<< _EOF
url: https://
$host
url: https://
$host
port:
$misskey_port
port:
$misskey_port
...
@@ -616,7 +617,7 @@ if $nginx_local; then
...
@@ -616,7 +617,7 @@ if $nginx_local; then
tput setaf 3
;
tput setaf 3
;
echo
"Process: copy and apply nginx config;"
echo
"Process: copy and apply nginx config;"
tput setaf 7
;
tput setaf 7
;
sed
-e
"s/example.tld/
$host
/g"
"/home/misskey/
$misskey_directory
/docs/examples/misskey.nginx"
>
/etc/nginx/conf.d/misskey.conf
;
sed
-e
"s/example.tld/
$host
/g"
"/home/
$
misskey
_user
/
$misskey_directory
/docs/examples/misskey.nginx"
>
/etc/nginx/conf.d/misskey.conf
;
nginx
-t
;
nginx
-t
;
systemctl restart nginx
;
systemctl restart nginx
;
fi
fi
...
@@ -626,7 +627,7 @@ if [ $method == "systemd" ]; then
...
@@ -626,7 +627,7 @@ if [ $method == "systemd" ]; then
#region work with misskey user
#region work with misskey user
su
"
$misskey_user
"
<<
MKEOF
;
su
"
$misskey_user
"
<<
MKEOF
;
set -eu;
set -eu;
cd ~/
$misskey_directory
;
cd
"
~/
$misskey_directory
"
;
tput setaf 3;
tput setaf 3;
echo "Process: install npm packages;"
echo "Process: install npm packages;"
...
@@ -667,7 +668,7 @@ Description=Misskey daemon
...
@@ -667,7 +668,7 @@ Description=Misskey daemon
Type=simple
Type=simple
User=
$misskey_user
User=
$misskey_user
ExecStart=
$(
command
-v
npm
)
start
ExecStart=
$(
command
-v
npm
)
start
WorkingDirectory=/home/misskey/
$misskey_directory
WorkingDirectory=/home/
$
misskey
_user
/
$misskey_directory
Environment="NODE_ENV=production"
Environment="NODE_ENV=production"
TimeoutSec=60
TimeoutSec=60
StandardOutput=syslog
StandardOutput=syslog
...
...
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