Compare commits
1 Commits
master
...
c1357cb6c9
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c1357cb6c9 |
211
.drone.star
211
.drone.star
@@ -1,141 +1,90 @@
|
|||||||
def main(ctx):
|
def main(ctx):
|
||||||
return [
|
return [
|
||||||
stepPR("amd64", "motsognir"),
|
stepPR("amd64"),
|
||||||
stepPR("arm64", "motsognir"),
|
#stepPR("arm64"),
|
||||||
stepMergeMaster("amd64", "motsognir"),
|
#stepMergeMaster("amd64"),
|
||||||
stepMergeMaster("arm64", "motsognir"),
|
#stepMergeMaster("arm64"),
|
||||||
stepBuildWeekly("amd64", "motsognir"),
|
|
||||||
stepBuildWeekly("arm64", "motsognir"),
|
|
||||||
|
|
||||||
stepPR("amd64", "webtest"),
|
|
||||||
stepPR("arm64", "webtest"),
|
|
||||||
stepMergeMaster("amd64", "webtest"),
|
|
||||||
stepMergeMaster("arm64", "webtest"),
|
|
||||||
stepBuildWeekly("amd64", "webtest"),
|
|
||||||
stepBuildWeekly("arm64", "webtest"),
|
|
||||||
|
|
||||||
stepPR("amd64", "unbound"),
|
|
||||||
stepPR("arm64", "unbound"),
|
|
||||||
stepMergeMaster("amd64", "unbound"),
|
|
||||||
stepMergeMaster("arm64", "unbound"),
|
|
||||||
stepBuildWeekly("amd64", "unbound"),
|
|
||||||
stepBuildWeekly("arm64", "unbound"),
|
|
||||||
|
|
||||||
notify(ctx),
|
|
||||||
]
|
]
|
||||||
|
|
||||||
def notify(ctx):
|
|
||||||
return {
|
def stepPR(arch):
|
||||||
|
return {
|
||||||
"kind": "pipeline",
|
"kind": "pipeline",
|
||||||
"type": "docker",
|
"type": "docker",
|
||||||
"name": "matrix-notifications",
|
"name": "docker-build-%s" % (arch),
|
||||||
"clone": {
|
"platform": {
|
||||||
"disable": True,
|
"os": "linux",
|
||||||
|
"arch": arch,
|
||||||
},
|
},
|
||||||
"steps": [
|
"steps": [
|
||||||
{
|
{
|
||||||
"name": "notify",
|
"name": "build-image-%s" % (arch),
|
||||||
"image": "plugins/matrix",
|
"image": "plugins/docker",
|
||||||
"settings": {
|
"settings": {
|
||||||
"homeserver": {
|
"dockerfile": "motsognir/Dockerfile",
|
||||||
"from_secret": "matrix-homeserver"
|
"repo": "dragonchaser/motsognir",
|
||||||
},
|
"dry_run": "true",
|
||||||
"roomid": {
|
"purge" : "false",
|
||||||
"from_secret": "matrix-room"
|
"tag": "latest-%s" % (arch),
|
||||||
},
|
|
||||||
"username": {
|
|
||||||
"from_secret": "matrix-user"
|
|
||||||
},
|
|
||||||
"password": {
|
|
||||||
"from_secret": "matrix-password"
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "publish-image-dockerhub-%s" % (arch),
|
||||||
|
"image": "plugins/docker",
|
||||||
|
"settings": {
|
||||||
|
"dockerfile": "motsognir/Dockerfile",
|
||||||
|
"repo": "dragonchaser/motsognir",
|
||||||
|
"dry_run": "true",
|
||||||
|
"purge" : "false",
|
||||||
|
"tag": "latest-%s" % (arch),
|
||||||
|
"username": {
|
||||||
|
"from_secret": "dockerhub-userxx"
|
||||||
|
},
|
||||||
|
"password": {
|
||||||
|
"from_secret": "dockerhub-passwordxx"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "publish-image-quay-%s" % (arch),
|
||||||
|
"image": "plugins/docker",
|
||||||
|
"settings": {
|
||||||
|
"dockerfile": "motsognir/Dockerfile",
|
||||||
|
"repo": "quay.io/dragonchaser/motsognir",
|
||||||
|
"dry_run": "true",
|
||||||
|
"tag": "latest-%s" % (arch),
|
||||||
|
"username": {
|
||||||
|
"from_secret": "dockerhub-userxx"
|
||||||
|
},
|
||||||
|
"password": {
|
||||||
|
"from_secret": "dockerhub-passwordxx"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
"depends_on": [
|
|
||||||
"docker-build-motsognir-amd64",
|
|
||||||
"docker-build-motsognir-arm64",
|
|
||||||
"docker-build-webtest-amd64",
|
|
||||||
"docker-build-webtest-arm64",
|
|
||||||
"docker-build-unbound-amd64",
|
|
||||||
"docker-build-unbound-arm64",
|
|
||||||
|
|
||||||
"docker-publish-motsognir-amd64",
|
|
||||||
"docker-publish-motsognir-arm64",
|
|
||||||
"docker-publish-webtest-amd64",
|
|
||||||
"docker-publish-webtest-arm64",
|
|
||||||
"docker-publish-unbound-amd64",
|
|
||||||
"docker-publish-unbound-arm64",
|
|
||||||
|
|
||||||
"docker-publish-weekly-motsognir-amd64",
|
|
||||||
"docker-publish-weekly-motsognir-arm64",
|
|
||||||
"docker-publish-weekly-webtest-amd64",
|
|
||||||
"docker-publish-weekly-webtest-arm64",
|
|
||||||
"docker-publish-weekly-unbound-amd64",
|
|
||||||
"docker-publish-weekly-unbound-arm64",
|
|
||||||
],
|
|
||||||
"trigger": {
|
|
||||||
"ref": [
|
|
||||||
"refs/heads/master",
|
|
||||||
"refs/heads/release*",
|
|
||||||
"refs/tags/**",
|
|
||||||
"refs/pull/**",
|
|
||||||
],
|
|
||||||
"status": [
|
|
||||||
"failure",
|
|
||||||
"success",
|
|
||||||
],
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
def stepPR(arch, path):
|
|
||||||
return {
|
|
||||||
"kind": "pipeline",
|
|
||||||
"type": "docker",
|
|
||||||
"name": "docker-build-%s-%s" % (path, arch),
|
|
||||||
"platform": {
|
|
||||||
"os": "linux",
|
|
||||||
"arch": arch,
|
|
||||||
},
|
|
||||||
"steps": [
|
|
||||||
{
|
|
||||||
"name": "build-image-%s-%s" % (path, arch),
|
|
||||||
"image": "plugins/docker",
|
|
||||||
"settings": {
|
|
||||||
"dockerfile": "%s/Dockerfile" % (path),
|
|
||||||
"repo": "dragonchaser/%s" % (path),
|
|
||||||
"dry_run": "true",
|
|
||||||
"tag": "latest-%s" % (arch),
|
|
||||||
}
|
|
||||||
},
|
|
||||||
],
|
|
||||||
"trigger": {
|
"trigger": {
|
||||||
"ref": [
|
"ref": [
|
||||||
"refs/pull/**",
|
"refs/pull/**",
|
||||||
],
|
],
|
||||||
"status": [
|
|
||||||
"success",
|
|
||||||
"failure"
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
def stepMergeMaster(arch, path):
|
def stepMergeMaster(arch):
|
||||||
return {
|
return {
|
||||||
"kind": "pipeline",
|
"kind": "pipeline",
|
||||||
"type": "docker",
|
"type": "docker",
|
||||||
"name": "docker-publish-%s-%s" % (path, arch),
|
"name": "docker-publish-%s" % (arch),
|
||||||
"platform": {
|
"platform": {
|
||||||
"os": "linux",
|
"os": "linux",
|
||||||
"arch": arch,
|
"arch": arch,
|
||||||
},
|
},
|
||||||
"steps": [
|
"steps": [
|
||||||
{
|
{
|
||||||
"name": "build-and-publish-image-%s-%s" % (path, arch),
|
"name": "build-build-and-publish-image-%s" % (arch),
|
||||||
"image": "plugins/docker",
|
"image": "plugins/docker",
|
||||||
"settings": {
|
"settings": {
|
||||||
"dockerfile": "%s/Dockerfile" % (path),
|
"dockerfile": "motsognir/Dockerfile",
|
||||||
"repo": "dragonchaser/%s" % (path),
|
"repo": "dragonchaser/motsognir",
|
||||||
"dry_run": "false",
|
"dry_run": "false",
|
||||||
"tag": "latest-%s" % (arch),
|
"tag": "latest-%s" % (arch),
|
||||||
"username": {
|
"username": {
|
||||||
@@ -151,49 +100,5 @@ def stepMergeMaster(arch, path):
|
|||||||
"ref": [
|
"ref": [
|
||||||
"refs/heads/master",
|
"refs/heads/master",
|
||||||
],
|
],
|
||||||
"status": [
|
},
|
||||||
"success",
|
|
||||||
"failure"
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
def stepBuildWeekly(arch, path):
|
|
||||||
return {
|
|
||||||
"kind": "pipeline",
|
|
||||||
"type": "docker",
|
|
||||||
"name": "docker-publish-weekly-%s-%s" % (path, arch),
|
|
||||||
"platform": {
|
|
||||||
"os": "linux",
|
|
||||||
"arch": arch,
|
|
||||||
},
|
|
||||||
"steps": [
|
|
||||||
{
|
|
||||||
"name": "build-and-publish-image-%s-%s" % (path, arch),
|
|
||||||
"image": "plugins/docker",
|
|
||||||
"settings": {
|
|
||||||
"dockerfile": "%s/Dockerfile" % (path),
|
|
||||||
"repo": "dragonchaser/%s" % (path),
|
|
||||||
"dry_run": "false",
|
|
||||||
"tag": "latest-%s" % (arch),
|
|
||||||
"username": {
|
|
||||||
"from_secret": "dockerhub-user"
|
|
||||||
},
|
|
||||||
"password": {
|
|
||||||
"from_secret": "dockerhub-password"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
],
|
|
||||||
"trigger": {
|
|
||||||
"ref": [
|
|
||||||
"refs/heads/master",
|
|
||||||
],
|
|
||||||
"event": [
|
|
||||||
"cron"
|
|
||||||
],
|
|
||||||
"cron": [
|
|
||||||
"weekly"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
}
|
|
||||||
43
.github/workflows/docker-image.yml
vendored
Normal file
43
.github/workflows/docker-image.yml
vendored
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
name: Docker Image CI
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ master ]
|
||||||
|
pull_request:
|
||||||
|
branches: [ master ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
env:
|
||||||
|
DOCKER_REGISTRY: ghcr.io
|
||||||
|
DOCKER_IMAGE: dragonchaser/motsognir
|
||||||
|
DOCKER_TARGET_PLATFORM: "linux/arm/v7,linux/arm64,linux/amd64"
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: crazy-max/ghaction-docker-buildx@v1
|
||||||
|
with:
|
||||||
|
version: latest
|
||||||
|
|
||||||
|
- name: Prepare
|
||||||
|
if: success()
|
||||||
|
id: prepare
|
||||||
|
run: |
|
||||||
|
echo ::set-output name=docker_platform::${DOCKER_TARGET_PLATFORM}
|
||||||
|
echo ::set-output name=docker_image::${DOCKER_REGISTRY}/${DOCKER_IMAGE}
|
||||||
|
#echo ::set-output name=version::${GITHUB_RUN_NUMBER}
|
||||||
|
echo ::set-output name=version::latest
|
||||||
|
|
||||||
|
- name: Log into registry
|
||||||
|
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
|
||||||
|
|
||||||
|
- name: Run Buildx
|
||||||
|
if: success()
|
||||||
|
run: |
|
||||||
|
cd motsognir
|
||||||
|
docker buildx build --platform ${{ steps.prepare.outputs.docker_platform }} --tag ${{ steps.prepare.outputs.docker_image }}:${{steps.prepare.outputs.version }} --file ./Dockerfile.arm32v7 --output type=image,push=true .
|
||||||
42
.github/workflows/ghrunner.yml
vendored
Normal file
42
.github/workflows/ghrunner.yml
vendored
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
name: Docker Image CI for GHRUNNER
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ master ]
|
||||||
|
pull_request:
|
||||||
|
branches: [ master ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
env:
|
||||||
|
DOCKER_REGISTRY: ghcr.io
|
||||||
|
DOCKER_IMAGE: dragonchaser/ghrunner
|
||||||
|
DOCKER_TARGET_PLATFORM: "linux/arm64,linux/amd64"
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: crazy-max/ghaction-docker-buildx@v1
|
||||||
|
with:
|
||||||
|
version: latest
|
||||||
|
|
||||||
|
- name: Prepare
|
||||||
|
if: success()
|
||||||
|
id: prepare
|
||||||
|
run: |
|
||||||
|
echo ::set-output name=docker_platform::${DOCKER_TARGET_PLATFORM}
|
||||||
|
echo ::set-output name=docker_image::${DOCKER_REGISTRY}/${DOCKER_IMAGE}
|
||||||
|
echo ::set-output name=version::latest
|
||||||
|
|
||||||
|
- name: Log into registry
|
||||||
|
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
|
||||||
|
|
||||||
|
- name: Run Buildx
|
||||||
|
if: success()
|
||||||
|
run: |
|
||||||
|
cd ghrunner
|
||||||
|
docker buildx build --platform ${{ steps.prepare.outputs.docker_platform }} --tag ${{ steps.prepare.outputs.docker_image }}:${{steps.prepare.outputs.version }} --file ./Dockerfile --output type=image,push=true .
|
||||||
12
README.md
12
README.md
@@ -1,12 +1,10 @@
|
|||||||
# dockerhub-autobuild
|
# dockerhub-autobuild
|
||||||
|
|
||||||
[](https://drone.services.datenschmutz.space/dragonchaser/dockerhub-autobuild)
|
|
||||||
|
|
||||||
This repo contains Dockerfiles used for autobuilding on Dockerhub.
|
This repo contains Dockerfiles used for autobuilding on Dockerhub.
|
||||||
No guarantee for completeness or functionality.
|
No guarantee for completeness or functionality.
|
||||||
|
|
||||||
| URL | Folder | Description | x86_64 | aarch64 |
|
|URL|Folder|Description|x86_64|arm32v7|aarch64|
|
||||||
| :-- | :----- | :---------- | :----: | :-----: |
|
|:--|:-----|:----------|:----:|:-----:|:-----:|
|
||||||
| [dragonchaser/webtest](https://hub.docker.com/r/dragonchaser/webtest) | webtest | A small container running ruby WebRick and serves static content from /web | x | x |
|
|[dragonchaser/webtest](https://hub.docker.com/r/dragonchaser/webtest)|webtest|A small container running ruby WebRick and serves static content from /web|x|x||
|
||||||
| [dragonchaser/motsognir](https://hub.docker.com/r/dragonchaser/motsognir) | motsognir | A container for the motsognir gopher server | x | x |
|
|[dragonchaser/motsognir](https://hub.docker.com/r/dragonchaser/motsognir) |motsognir|A container for the motsognir gopher server|x|x||
|
||||||
| [dragonchaser/unbound](https://hub.docker.com/r/dragonchaser/unbound) | motsognir | A container for unbound dns | x | x |
|
|[ghcr.io/dragonchaser/ghrunner](https://github.com/dragonchaser/dockerhub-autobuild/pkgs/container/ghrunner)|ghrunner |A container for running github runners |x| |x|
|
||||||
|
|||||||
16
ghrunner/Dockerfile
Normal file
16
ghrunner/Dockerfile
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
FROM ubuntu:latest
|
||||||
|
COPY entrypoint.sh /
|
||||||
|
ENV TZ=Europe/Berlin
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
RUN apt-get update \
|
||||||
|
&& apt-get -y install \
|
||||||
|
curl \
|
||||||
|
libdigest-sha-perl \
|
||||||
|
tzdata \
|
||||||
|
sudo
|
||||||
|
RUN useradd -ms /bin/bash runner
|
||||||
|
RUN usermod -aG sudo runner
|
||||||
|
WORKDIR /runner
|
||||||
|
RUN chown runner:runner /runner -Rfv
|
||||||
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
|
|
||||||
21
ghrunner/README.md
Normal file
21
ghrunner/README.md
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
# GHRUNNER
|
||||||
|
|
||||||
|
This is a small Dockerfile providing a github runner.
|
||||||
|
The images can be found `ghcr.io/dragonchaser/ghrunner:latest`.
|
||||||
|
Supported arches are:
|
||||||
|
- aarch64
|
||||||
|
- amd64
|
||||||
|
|
||||||
|
## Environment variables
|
||||||
|
```terminal
|
||||||
|
| Variable | Values | default |
|
||||||
|
|------------+----------------------------------------+----------------|
|
||||||
|
| `TOKEN` | token for runner from github | <unset> |
|
||||||
|
| `ARCH` | arm64, x64 | x64 |
|
||||||
|
| `OS` | linux,osx | linux |
|
||||||
|
| `ORG` | name of the github org | <unset> |
|
||||||
|
| `REPO` | name of the github repo | <unset> |
|
||||||
|
| `VERSION` | version of the github runner to user | 2.280.3 |
|
||||||
|
| `CHECKSUM` | checksum for the github runner version | valid checksum |
|
||||||
|
```
|
||||||
|
|
||||||
30
ghrunner/entrypoint.sh
Executable file
30
ghrunner/entrypoint.sh
Executable file
@@ -0,0 +1,30 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
ARCH=${ARCH:-x64}
|
||||||
|
VERSION=${VERSION:-2.280.3}
|
||||||
|
CHECKSUM=${CHECKSUM:-69dc323312e3c5547ba1e1cc46c127e2ca8ee7d7037e17ee6965ef6dac3c142b}
|
||||||
|
ORG=${ORG:-dragonchaser}
|
||||||
|
REPO=${REPO:-dockerhub-autobuild}
|
||||||
|
OS=${OS:-linux}
|
||||||
|
|
||||||
|
if [ -z "${ORG}" ]; then
|
||||||
|
echo "missing ORG, bailing out!"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "${REPO}" ]; then
|
||||||
|
echo "missing REPO, bailing out!"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "${TOKEN}" ]; then
|
||||||
|
echo "missing TOKEN, bailing out!"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
FILE="actions-runner-${OS}-${ARCH}-${VERSION}.tar.gz"
|
||||||
|
curl -o ${FILE} -L https://github.com/actions/runner/releases/download/v${VERSION}/${FILE}
|
||||||
|
echo "${CHECKSUM} ${FILE}" | shasum -a 256 -c
|
||||||
|
tar xzf ./${FILE}
|
||||||
|
./bin/installdependencies.sh
|
||||||
|
su runner -c "./config.sh --unattended --url https://github.com/${ORG}/${REPO} --token ${TOKEN} --name docker-runner-$(hostname) --labels=${ARCH},${OS},self-hosted"
|
||||||
|
while true; do
|
||||||
|
su runner -c "./run.sh"
|
||||||
|
done
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
FROM debian:latest
|
FROM debian:latest
|
||||||
LABEL maintainer="dragonchaser <autobuilds@datenschmutz.space>"
|
LABEL maintainer="dragonchaser <motsognir@datenschmutz.space>"
|
||||||
ENV VERSION=1.0.13
|
ENV VERSION=1.0.13
|
||||||
ENV TARBALL="motsognir-${VERSION}.tar.xz"
|
ENV TARBALL="motsognir-${VERSION}.tar.xz"
|
||||||
EXPOSE 70
|
EXPOSE 70
|
||||||
@@ -9,7 +9,7 @@ WORKDIR /build
|
|||||||
RUN wget "https://downloads.sourceforge.net/project/motsognir/v${VERSION}/${TARBALL}" \
|
RUN wget "https://downloads.sourceforge.net/project/motsognir/v${VERSION}/${TARBALL}" \
|
||||||
&& tar xfv "${TARBALL}"
|
&& tar xfv "${TARBALL}"
|
||||||
RUN cd $(echo "${TARBALL}" | sed -e "s/.tar.xz//g") && make all && make install
|
RUN cd $(echo "${TARBALL}" | sed -e "s/.tar.xz//g") && make all && make install
|
||||||
RUN apt-get -y purge build-essential
|
RUN apt-get -y purge wget build-essential
|
||||||
RUN rm -Rfv /etc/apt/sources.list.*
|
RUN rm -Rfv /etc/apt/sources.list.*
|
||||||
RUN rm -Rfv /build
|
RUN rm -Rfv /build
|
||||||
RUN useradd -ms /bin/bash -d /gopher gopher
|
RUN useradd -ms /bin/bash -d /gopher gopher
|
||||||
|
|||||||
@@ -4,16 +4,16 @@ A container for the motsognir gopher server http://motsognir.sourceforge.net/
|
|||||||
|
|
||||||
## Running locally
|
## Running locally
|
||||||
|
|
||||||
**amd64**
|
**x86_64**
|
||||||
|
|
||||||
```
|
```
|
||||||
$> docker run -p 70:70 -v /path/to/you/local/gopherfolder:/gopher dragonchaser/motsognir:latest-amd64
|
$> docker run -p 70:70 -v /path/to/you/local/gopherfolder:/gopher dragonchaser/motsognir:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
**arm64**
|
**arm32v7**
|
||||||
|
|
||||||
```
|
```
|
||||||
$> docker run -p 70:70 -v /path/to/you/local/gopherfolder:/gopher dragonchaser/motsognir:latest-arm64
|
$> docker run -p 70:70 -v /path/to/you/local/gopherfolder:/gopher dragonchaser/motsognir:latest-arm32v7
|
||||||
```
|
```
|
||||||
|
|
||||||
**Notes:**
|
**Notes:**
|
||||||
|
|||||||
@@ -1,8 +0,0 @@
|
|||||||
FROM debian:latest
|
|
||||||
LABEL maintainer="dragonchaser <autobuilds@datenschmutz.space>"
|
|
||||||
EXPOSE 5335/udp
|
|
||||||
RUN apt-get update \
|
|
||||||
&& apt-get -y install unbound netcat-traditional
|
|
||||||
COPY unbound/config.conf /etc/unbound/unbound.conf.d/
|
|
||||||
COPY unbound/entrypoint.sh /
|
|
||||||
ENTRYPOINT /entrypoint.sh
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
# unbound
|
|
||||||
|
|
||||||
A container for unbound https://github.com/NLnetLabs/unbound
|
|
||||||
|
|
||||||
## Running locally
|
|
||||||
|
|
||||||
**amd64**
|
|
||||||
|
|
||||||
```
|
|
||||||
$> docker run \
|
|
||||||
-p 53:53 \
|
|
||||||
-v /path/to/you/local/unboundfolder/conf:/etc/unbound \
|
|
||||||
-v /path/to/you/local/unboundfolder/lib:/var/lib/unbound \
|
|
||||||
dragonchaser/unbound:latest-amd64
|
|
||||||
```
|
|
||||||
|
|
||||||
**arm64**
|
|
||||||
|
|
||||||
```
|
|
||||||
$> docker run \
|
|
||||||
-p 53:53 \
|
|
||||||
-v /path/to/you/local/unboundfolder/conf:/etc/unbound \
|
|
||||||
-v /path/to/you/local/unboundfolder/lib:/var/lib/unbound \
|
|
||||||
dragonchaser/unbound:latest-arm64
|
|
||||||
``**
|
|
||||||
|
|
||||||
***Note:***
|
|
||||||
|
|
||||||
The container will expose the dns port on 5335.
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
server:
|
|
||||||
access-control: 0.0.0.0/0 allow
|
|
||||||
interface: 0.0.0.0
|
|
||||||
port: 5335
|
|
||||||
do-ip6: no
|
|
||||||
do-ip4: yes
|
|
||||||
do-udp: yes
|
|
||||||
do-tcp: yes
|
|
||||||
# Set number of threads to use
|
|
||||||
num-threads: 8
|
|
||||||
# Hide DNS Server info
|
|
||||||
hide-identity: yes
|
|
||||||
hide-version: yes
|
|
||||||
# Limit DNS Fraud and use DNSSEC
|
|
||||||
harden-glue: yes
|
|
||||||
harden-dnssec-stripped: yes
|
|
||||||
harden-referral-path: yes
|
|
||||||
use-caps-for-id: yes
|
|
||||||
harden-algo-downgrade: yes
|
|
||||||
qname-minimisation: yes
|
|
||||||
aggressive-nsec: yes
|
|
||||||
rrset-roundrobin: yes
|
|
||||||
# Minimum lifetime of cache entries in seconds
|
|
||||||
cache-min-ttl: 300
|
|
||||||
# Configure TTL of Cache
|
|
||||||
cache-max-ttl: 14400
|
|
||||||
# Optimizations
|
|
||||||
msg-cache-slabs: 8
|
|
||||||
rrset-cache-slabs: 8
|
|
||||||
infra-cache-slabs: 8
|
|
||||||
key-cache-slabs: 8
|
|
||||||
serve-expired: yes
|
|
||||||
serve-expired-ttl: 3600
|
|
||||||
edns-buffer-size: 1232
|
|
||||||
prefetch: yes
|
|
||||||
prefetch-key: yes
|
|
||||||
unwanted-reply-threshold: 10000000
|
|
||||||
# Set cache size
|
|
||||||
rrset-cache-size: 256m
|
|
||||||
msg-cache-size: 128m
|
|
||||||
# increase buffer size so that no messages are lost in traffic spikes
|
|
||||||
#so-rcvbuf: 1m
|
|
||||||
private-address: 192.168.0.0/16
|
|
||||||
private-address: 169.254.0.0/16
|
|
||||||
private-address: 172.16.0.0/12
|
|
||||||
private-address: 10.0.0.0/8
|
|
||||||
private-address: fd00::/8
|
|
||||||
private-address: fe80::/10
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
unbound-checkconf
|
|
||||||
unbound -d
|
|
||||||
@@ -1,12 +1,12 @@
|
|||||||
FROM debian:latest
|
FROM debian:latest
|
||||||
LABEL maintainer="dragonchaser <autobuilds@datenschmutz.space>"
|
LABEL maintainer="dragonchaser <crichter@suse.de>"
|
||||||
RUN apt-get update \
|
RUN apt-get update \
|
||||||
&& apt-get install -y ruby \
|
&& apt-get install -y ruby \
|
||||||
&& rm -rf /var/lib/apt/lists/* \
|
&& rm -rf /var/lib/apt/lists/* \
|
||||||
&& mkdir /web \
|
&& mkdir /web \
|
||||||
&& chmod 0777 /web
|
&& chmod 0777 /web
|
||||||
COPY ./webtest/entrypoint.sh /bin
|
COPY ./entrypoint.sh /bin
|
||||||
COPY ./webtest/index.html /web
|
COPY ./index.html /web
|
||||||
WORKDIR /web
|
WORKDIR /web
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
ENTRYPOINT entrypoint.sh
|
ENTRYPOINT entrypoint.sh
|
||||||
|
|||||||
Reference in New Issue
Block a user