0a908876 by Adam Heath

Importing into a fresh repository.

1 parent a049cf3e
1 FROM debian:jessie
2
3 ADD /overlay/ /
4
5 RUN ["use-apt-mirror", "http.us.debian.org"]
6
7 RUN ["apt-docker", \
8 "-y", "dist-upgrade", \
9 ";", "-y", "install", "apt-utils", "libterm-readline-perl-perl", \
10 ";", "-y", "install", "apt-transport-https", "ca-certificates", \
11 "rsyslog", \
12 "sudo", \
13 "git", "wget", \
14 "less", \
15 ";" ]
16
17
18 # "vim", "nano-", "vim-tiny-", \
19 # "less", \
20 # "screen", "tmux", \
21
1 version: '2'
2
3 services:
4 build:
5 image: docker.brainfood.com/debian-support
6 build:
7 context: .
8 args:
9 - http_proxy
10 - https_proxy
11
1 APT::Install-Suggests false;
2 APT::Install-Recommends false;
1 Package: *
2 Pin: release l=Debian-Security
3 Pin-Priority: 1000
4
5 Package: *
6 Pin: release a=stable
7 Pin-Priority: 900
8
9 Package: *
10 Pin: release a=testing
11 Pin-Priority: 750
12
13 Package: *
14 Pin: release l=Debian Backports
15 Pin-Priority: 750
16
1 deb http://http.us.debian.org/debian jessie-backports main
1 deb http://http.us.debian.org/debian testing main
1 #!/bin/bash
2
3 set -e
4
5 declare -a cmd
6
7 apt-get update
8
9 export DEBIAN_FRONTEND=noninteractive RUNLEVEL=1
10 while [[ $# -gt 0 ]]; do
11 if [[ $1 = ";" ]]; then
12 apt-get "${cmd[@]}"
13 cmd=()
14 else
15 cmd+=("$1")
16 fi
17 shift
18 done
19 if [[ ${#cmd[*]} -gt 0 ]]; then
20 apt-get "${cmd[@]}"
21 cmd=()
22 fi
23 rm -rf /var/lib/apt/lists/ /var/cache/apt/archives/*.deb
1 #!/bin/sh
2
3 set -ex
4 url="$1"
5 target="$2"
6 shift 2
7
8 rm -rf /tmp/docker-download-file
9 mkdir /tmp/docker-download-file
10
11 cd /tmp/docker-download-file
12
13 wget "$url"
14
15 set -- *
16 cp "$1" "$target.tmp"
17 mv "$target.tmp" "$target"
18
19 cd /
20 rm -rf /tmp/docker-download-file
1 #!/bin/bash
2
3 set -e
4 url="$1"
5 bundle_file="$2"
6
7 shift 2
8
9 declare -a git_args
10
11 rm -rf /tmp/build
12 mkdir -p /tmp/build
13 if [[ -e $bundle_file ]]; then
14 git clone --mirror --bare "$bundle_file" "/tmp/build/base.git"
15 git_args+=(
16 --reference "/tmp/build/base.git"
17 )
18 ls -l "$bundle_file"
19 fi
20 git clone --mirror --bare "${git_args[@]}" "$url" "/tmp/build/repo.git"
21 GIT_DIR="/tmp/build/repo.git" git bundle create "/tmp/build/new-bundle.git" --all
22
23 ls -l "/tmp/build/new-bundle.git"
24
25 cp -a "/tmp/build/new-bundle.git" "$bundle_file.tmp"
26 if [[ -e $bundle_file ]]; then
27 chown --reference "$bundle_file" "$bundle_file.tmp"
28 chmod --reference "$bundle_file" "$bundle_file.tmp"
29 fi
30 mv "$bundle_file.tmp" "$bundle_file"
31
32 rm -rf /tmp/build
33
1 #!/bin/sh
2
3 data_dir="$1"
4 data_name="$2"
5 shift 2
6
7 mkdir -p /var/lib/docker-init/data
8 tar -C "$data_dir" -c . | gzip -9v > "/var/lib/docker-init/data/$data_name.data.tar.gz"
9 find "$data_dir" -mindepth 1 -maxdepth 1 -exec rm -rf '{}' ';'
1 #!/bin/sh
2
3 find /etc/apt -type f -print0 | xargs -0 sed -i -e "s,http://httpredir.debian.org,http://$1,g"