Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
M
materials
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Test Cases
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
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
osak
materials
Commits
a00c331a
Commit
a00c331a
authored
Sep 13, 2012
by
Daniel Schulte
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of www.fsmpi.rwth-aachen.de:lip
parents
44c285b7
5d6e57f9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
106 additions
and
0 deletions
+106
-0
shellscripte/usbrepo/create_offline_repo.sh
shellscripte/usbrepo/create_offline_repo.sh
+22
-0
shellscripte/usbrepo/infuse_offline_repo.sh
shellscripte/usbrepo/infuse_offline_repo.sh
+38
-0
shellscripte/usbrepo/mount-stick-repo.sh
shellscripte/usbrepo/mount-stick-repo.sh
+46
-0
No files found.
shellscripte/usbrepo/create_offline_repo.sh
0 → 100644
View file @
a00c331a
#!/bin/bash
PKG_LIST
=
"linux-firmware-nonfree swi-prolog cowsay fish get-flash-videos gnome haskell-platform java7-jdk imagemagick rxvt-unicode moc nethack-console scrot sl tmux vim xcowsay zsh zsh-doc texmaker gimp pidgin smplayer subversion git lftp inkscape"
DESTINATION
=
"/isodevice"
SECTIONNAME
=
lipoffline
ARCHITECTURE
=
$1
ARCHIVE_DESTINATION
=
$DESTINATION
/archives
REL_DISTS_PATH
=
dists/main/
$SECTIONNAME
/binary-
$ARCHITECTURE
PKG_DESTINATION
=
$ARCHIVE_DESTINATION
/
$REL_DISTS_PATH
#begin
echo
"creating structure..."
mkdir
-p
$PKG_DESTINATION
/
echo
"done."
echo
"downloading archives. this may take some time..."
wget
-nc
-P
$PKG_DESTINATION
$(
apt-get
-o
APT::Architecture
=
$ARCHITECTURE
install
--reinstall
--print-uris
-qq
$PKG_LIST
|
cut
-d
"'"
-f2
)
#wget -nc -P $PKG_DESTINATION $(apt-get -o APT::Architecture=$ARCHITECTURE install --reinstall --allow-unauthenticated --print-uris -qq $PKG_LIST | cut -d"'" -f2)
echo
"done."
echo
"creating meta files..."
cd
$ARCHIVE_DESTINATION
apt-ftparchive packages
$REL_DISTS_PATH
>
$REL_DISTS_PATH
/Packages
gzip
$REL_DISTS_PATH
/Packages
echo
"done."
shellscripte/usbrepo/infuse_offline_repo.sh
0 → 100644
View file @
a00c331a
#!/bin/bash
PKG_LIST
=
"cowsay fish get-flash-videos gnome haskell-platform java7-jdk imagemagick rxvt-unicode moc nethack-console scrot sl tmux vim xcowsay zsh zsh-doc texmaker gimp pidgin smplayer subversion git lftp inkscape"
source
mount-stick-repo.sh
#detect mountpoint
if
[
-n
$MPOINT
]
;
then
SOURCE_PATH
=
"
$MPOINT
"
#check if we have root perms?
MERGE_DIR
=
$(
mktemp
-d
)
CACHE_DIR
=
"/var/cache/apt/archives/"
ARCH
=
"i386"
if
[
"
$(
uname
-m
)
"
=
"x86_64"
]
;
then
ARCH
=
"amd64"
fi
OVERLAY_DIR
=
"
$SOURCE_PATH
/archives/dists/main/lipoffline/binary-
$ARCH
/"
echo
"Detected architecture
$ARCH
-> overlay dir is
$OVERLAY_DIR
"
# test if there is already an overlayfs at CACHE_DIR
if
[
"
$(
stat
--format
%m
"
$CACHE_DIR
"
)
"
=
"
${
CACHE_DIR
%/
}
"
]
then
echo
"The Overlayfs is already there. Using it."
else
echo
"Making an overlay FS with your repository."
mkdir
-p
"
$MERGE_DIR
"
mount
-t
overlayfs
-o
"rw,lowerdir=
$OVERLAY_DIR
,upperdir=
$CACHE_DIR
"
overlayfs
"
$MERGE_DIR
"
mount
--move
"
$MERGE_DIR
"
"
$CACHE_DIR
"
rmdir
"
$MERGE_DIR
"
fi
else
echo
"No stick, no repo; good luck."
fi
apt-get
install
$APT_OPTIONS
$PKG_LIST
#exec lip install script here?
#end;
shellscripte/usbrepo/mount-stick-repo.sh
0 → 100644
View file @
a00c331a
#! /bin/bash
#find device
DEV
=
"
$(
blkid
-t
"LABEL=MultiBoot"
-o
device
)
"
while
[
-z
"
$DEV
"
]
;
do
echo
"Der LIP-Install-USB-Stick wurde nicht gefunden."
echo
"Jetzt einstecken oder ohne Weitermachen"
select
i
in
"Stick ist jetzt gesteckt"
\
"Ohne Stick Weitermachen"
\
"Installation abbrechen"
;
do
case
$i
in
"Stick ist jetzt gesteckt"
)
DEV
=
"
$(
blkid
-t
"LABEL=MultiBoot"
-o
device
)
"
;;
"Ohne Stick Weitermachen"
)
DEV
=
'-nomount-'
;;
"Installation abbrechen"
)
exit
0
;;
*
)
echo
"Das sollte nicht passieren. Helfer fragen."
exit
99
;;
esac
break
done
done
if
[
"
$DEV
"
=
"-nomount-"
]
;
then
echo
"Mache ohne USB-Stick weiter."
MPOINT
=
""
#exit 0
else
echo
"Stick gefunden als
$DEV
"
# ask udisks to mount it always.
udisks
--mount
"
$DEV
"
# see where it is mounted
DEVFILE
=
${
DEV
#/dev/
}
MPOINT
=
"
$(
qdbus
--system
org.freedesktop.UDisks /org/freedesktop/UDisks/devices/
${
DEVFILE
}
org.freedesktop.DBus.Properties.Get org.freedesktop.UDisks.Device
"DeviceMountPaths"
|
head
-n1
)
"
echo
"Der Stick it als '
$MPOINT
' gemountet"
fi
#end;
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