Skip to content

Commit

Permalink
Updates (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
adriananeci authored Jan 25, 2024
1 parent 248be7a commit 9d73a1b
Show file tree
Hide file tree
Showing 4 changed files with 65 additions and 39 deletions.
18 changes: 18 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Please see the documentation for all configuration options: https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
# github-actions
- directory: "/"
package-ecosystem: "github-actions"
schedule:
interval: "weekly"
time: "09:00"
# Use Europe/Bucharest Standard Time (UTC +02:00)
timezone: "Europe/Bucharest"
commit-message:
prefix: "dependabot"
include: scope
labels:
- "kind/cleanup"
- "dependabot"
70 changes: 34 additions & 36 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ name: CI
on:
push:
branches:
- master
- main
tags:
- 'v*.*.*'
schedule:
Expand All @@ -31,11 +31,11 @@ jobs:
steps:
# Checks out a copy of your repository on the ubuntu-latest machine
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4

# Runs the Super-Linter action
- name: Run Super-Linter
uses: github/super-linter@v3
uses: github/super-linter@v6
env:
DEFAULT_BRANCH: main
VALIDATE_BASH: true
Expand All @@ -44,7 +44,7 @@ jobs:
VALIDATE_MARKDOWN: true
VALIDATE_YAML: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Build and publish debug docker iamge
# Build and publish debug docker image
build_and_push:
# lint job must complete successfully before build_and_push job begins
needs:
Expand All @@ -53,37 +53,35 @@ jobs:
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Checkout
uses: actions/checkout@v2
# - name: Docker meta
# id: docker_meta
# uses: crazy-max/ghaction-docker-meta@v1
# with:
# images: aaneci/debug
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
if: github.event_name != 'pull_request'
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Set outputs
id: vars
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- name: Build and push
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64,linux/386
push: ${{ github.event_name != 'pull_request' }}
tags: |
aaneci/debug:latest
aaneci/debug:${{ steps.vars.outputs.sha_short }}
labels: |
debug=all_in_one
- uses: actions/checkout@v4
with:
fetch-depth: 0 # this is important, otherwise it won't checkout the full tree (i.e. no previous tags)
- # Add support for more platforms with QEMU (optional)
# https://github.com/docker/setup-qemu-action
name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Set outputs
id: vars
run: echo "::set-output name=sha_short::$(git rev-parse --short HEAD)"
- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
platforms: linux/amd64,linux/arm64,linux/386
push: ${{ github.event_name != 'pull_request' }}
tags: |
aaneci/debug:latest
aaneci/debug:${{ steps.vars.outputs.sha_short }}
labels: |
debug=all_in_one
# tags: ${{ steps.docker_meta.outputs.tags }}
# labels: ${{ steps.docker_meta.outputs.labels }}
14 changes: 12 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ RUN apk add --no-cache build-base git bash bash-completion ncurses vim tmux jq
# network
RUN apk add --no-cache bind-tools iputils tcptraceroute busybox-extras tcpdump curl wget nmap tcpflow iftop net-tools \
mtr netcat-openbsd bridge-utils iperf ngrep openldap-clients \
&& go get github.com/redsift/dnstrace \
&& dnstrace --completion-script-bash > ~/.bashrc
&& go install github.com/rs/dnstrace@latest

# certificates
RUN apk add --no-cache ca-certificates openssl
Expand All @@ -22,4 +21,15 @@ RUN curl -LO "https://storage.googleapis.com/kubernetes-release/release/$(curl -
&& chmod +x ./kubectl \
&& mv ./kubectl /usr/local/bin/kubectl

# clusterctl
RUN curl -L https://github.com/kubernetes-sigs/cluster-api/releases/latest/download/clusterctl-linux-amd64 -o clusterctl \
&& chmod +x ./clusterctl \
&& mv ./clusterctl /usr/local/bin/clusterctl

# argocd
RUN curl -L https://github.com/argoproj/argo-cd/releases/latest/download/argocd-linux-amd64 -o argocd \
&& chmod +x ./argocd \
&& mv ./argocd /usr/local/bin/argocd


CMD [ "bash" ]
2 changes: 1 addition & 1 deletion Readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![GitHub Super-Linter](https://github.com/adriananeci/debug_container/workflows/CI/badge.svg)](https://github.com/adriananeci/debug_container/actions?query=workflow%3ACI)
[![Super-Linter](https://github.com/adriananeci/debug_container/workflows/ci.yaml/badge.svg)](https://github.com/marketplace/actions/super-linter)

# Debug docker container

Expand Down

0 comments on commit 9d73a1b

Please sign in to comment.