Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.package
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Arnaud Véron
slapos.package
Commits
a3a5c3bc
Commit
a3a5c3bc
authored
Jul 29, 2013
by
Jondy Zhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos-cygwin-bootstrip:
add function show_usage add function check_os_is_wow64
parent
a9a9a49c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
22 deletions
+32
-22
windows/scripts/slapos-cygwin-bootstrip.sh
windows/scripts/slapos-cygwin-bootstrip.sh
+32
-22
No files found.
windows/scripts/slapos-cygwin-bootstrip.sh
View file @
a3a5c3bc
#! /bin/bash
#! /bin/bash
#
#
# This script is used to build a bootstrip slapos in the cywin.
function
check_os_is_wow64
()
#
{
# Usage:
[[
$(
uname
)
==
CYGWIN_NT-
*
-WOW64
]]
#
}
# ./slapos-cygwin-bootstrip.sh
readonly
-f
check_os_is_wow64
#
# Before run this script, type the following command in the windows
function
show_usage
()
# command console to install cygwin:
{
#
echo
"This script is used to build a bootstrip slapos in the cywin."
# setup_cygwin.bat C:\slapos-bootstrip network
echo
""
#
echo
"Usage:"
# Then sign up slapos.org, got the following certificate files:
echo
""
#
echo
" ./slapos-cygwin-bootstrip.sh"
# certificate
echo
""
# key
echo
"Before run this script, type the following command in the windows"
#
echo
"command console to install cygwin:"
# computer.key
echo
""
# computer.crt
echo
" setup_cygwin.bat C:
\s
lapos-bootstrip network"
#
echo
""
# save them in your home path.
echo
"Then sign up slapos.org, got the following certificate files:"
#
echo
""
echo
" certificate"
echo
" key"
echo
" computer.key"
echo
" computer.crt"
echo
""
echo
"save them in your home path."
echo
""
}
readonly
-f
show_usage
export
PATH
=
/usr/local/bin:/usr/bin:/usr/sbin:/sbin:/bin:
$PATH
export
PATH
=
/usr/local/bin:/usr/bin:/usr/sbin:/sbin:/bin:
$PATH
if
!
source
/usr/share/csih/cygwin-service-installation-helper.sh
;
then
if
!
source
/usr/share/csih/cygwin-service-installation-helper.sh
;
then
echo
"Error: Missing csih package."
echo
"Error: Missing csih package."
...
@@ -97,7 +107,7 @@ for _cmdname in ip useradd usermod groupadd brctl tunctl ; do
...
@@ -97,7 +107,7 @@ for _cmdname in ip useradd usermod groupadd brctl tunctl ; do
done
done
if
[[
!
-x
/usr/bin/ipwin.exe
]]
;
then
if
[[
!
-x
/usr/bin/ipwin.exe
]]
;
then
if
[[
$(
uname
)
==
CYGWIN_NT-
*
-WOW64
]]
;
then
if
check_os_is_wow64
;
then
wget http://dashingsoft.com/products/slapos/ipwin_x64.exe
-O
/usr/bin/ipwin.exe
||
wget http://dashingsoft.com/products/slapos/ipwin_x64.exe
-O
/usr/bin/ipwin.exe
||
csih_error
"download ipwin_x64.exe failed"
csih_error
"download ipwin_x64.exe failed"
csih_inform
"download ipwin_x64.exe OK"
csih_inform
"download ipwin_x64.exe OK"
...
...
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