Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
majora-go
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
majora
majora-go
Commits
76add2aa
Commit
76add2aa
authored
Oct 17, 2021
by
wei.xuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:fix startup.sh
parent
826549c2
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
72 additions
and
9 deletions
+72
-9
exec.sh
conf/exec.sh
+10
-0
majora-dev.ini
conf/majora-dev.ini
+20
-0
majora.ini
conf/majora.ini
+1
-1
start.sh
conf/start.sh
+40
-6
release.sh
release.sh
+1
-2
No files found.
conf/exec.sh
0 → 100755
View file @
76add2aa
#!/bin/bash
CURDIR
=
$(
cd
$(
dirname
"
$0
"
)
;
pwd
)
CONF
=
$CURDIR
/majora.ini
chmod
+x majora
echo
"
$CURDIR
"
/majora
-conf
"
$CONF
"
exec
"
$CURDIR
"
/majora
-conf
"
$CONF
"
\ No newline at end of file
conf/majora-dev.ini
0 → 100644
View file @
76add2aa
tunnel_addr
=
aoba.vip:5879
dns_server
=
114.114.114.114:53
;bind to local ip
;local_ip = 192.168.0.100
;for performance pprof 0 is close
;pprof_port = 0
disable_update
=
false
; default is info
log_level
=
0
reconn_interval
=
5s
;client_id =
[extra]
account
=
superman
[redial]
;command = /bin/bash
;exec_path = /root/ppp_auto_with_auth.sh
;redial_duration = 5m
;
wait_time
=
10s
\ No newline at end of file
conf/majora.ini
View file @
76add2aa
tunnel_addr
=
aoba.vip
:5879
tunnel_addr
=
majora.virjar.com
:5879
dns_server
=
114.114.114.114:53
dns_server
=
114.114.114.114:53
;bind to local ip
;bind to local ip
;local_ip = 192.168.0.100
;local_ip = 192.168.0.100
...
...
conf/start.sh
100755 → 100644
View file @
76add2aa
#!/bin/bash
#!/usr/bin/env bash
CURDIR
=
$(
cd
$(
dirname
"
$0
"
)
;
pwd
)
CONF
=
$CURDIR
/majora.ini
.
/etc/profile
.
/root/.bash_profile
chmod
+x majora
echo
"
$CURDIR
"
/majora
-conf
"
$CONF
"
echo
'shutdown majora-cli server'
now_dir
=
`
pwd
`
exec
"
$CURDIR
"
/majora
-conf
"
$CONF
"
cd
`
dirname
$0
`
\ No newline at end of file
script_dir
=
`
pwd
`
function
getPid
(){
echo
`
ps
-ef
|
grep
"majora"
|
grep
-v
"grep"
|
grep
-v
"startup.sh"
|
awk
'{print $2}'
`
}
remote_pid
=
`
getPid
`
echo
remote_pid:
${
remote_pid
}
if
[[
-n
"
${
remote_pid
}
"
]]
;
then
echo kill
pid
${
remote_pid
}
kill
-9
${
remote_pid
}
fi
echo
"start majora-cli server"
sleep
2
remote_pid
=
`
getPid
`
if
[[
-n
"
${
remote_pid
}
"
]]
;
then
# 被supervisor自动守护
exit
0
fi
std_log
=
../log
if
[[
!
-d
${
std_log
}
]]
;
then
mkdir
${
std_log
}
fi
nohup
bash exec.sh
>>
${
std_log
}
2>&1 &
sleep
2
remote_pid
=
`
getPid
`
echo
"remote pid:
${
remote_pid
}
"
\ No newline at end of file
release.sh
View file @
76add2aa
...
@@ -41,8 +41,7 @@ for os in $os_all; do
...
@@ -41,8 +41,7 @@ for os in $os_all; do
mkdir
${
majora_path
}
mkdir
${
majora_path
}
mv
./majora_
${
os
}
_
${
arch
}
${
majora_path
}
/majora
mv
./majora_
${
os
}
_
${
arch
}
${
majora_path
}
/majora
fi
fi
cp
-rf
../conf/majora.ini
${
majora_path
}
cp
-rf
../conf/
*
${
majora_path
}
cp
-rf
../conf/start.sh
${
majora_path
}
# packages
# packages
cd
./packages
cd
./packages
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment