mirror of
https://github.com/BretFisher/shpod.git
synced 2026-05-23 18:02:49 +00:00
Merge in upstream refactor for multiplatform awesomesauce (#42)
* Changes stern to point to stern/stern * ♻️ Update Stern to use stern/stern; get it from the GHCR image; update curl commands * Update README to mention Bret's fork which supports ARM * ♻️ Bump up versions and fix krew missing from PATH Fixes #12 * Add alias k=kubectl + completion Closes #11 * Update shpod.yaml Remove `imagePullPolicy`; it will default to `Always` since we're using the `:latest` tag. * ✏️ Change default editor (for kubectl edit) to vim * ⏫ Update krew install URL * ⚙️ Add GHA workflow to build+push to GHCR and Docker Hub * 🏭️ Refactor Dockerfile to log as non-root Multiple improvements here: - start a shell with the k8s user instead of root - when running without a tty, start an SSH server instead of a login shell - move shell setup to bash_profile instead of Dockerfile - add a helper script to set up tailhist - add motd support * ➕ Add 'tree' and 'kustomize' * ⏫ Upgrade to Compose v2 and add completion for a bunch of tools * 🔧 Minor fixes and tweaks * ➕ Add regclient tools (regbot, regctl, regsync) * 📃 Generate kubeconfig + update docs * ➕ Add kube-linter * ♻️ Refactor Dockerfile to leverage BuildKit parallelism * 🧹 Build httping instead of using a sketchy binary * 🧹 Move jid version to an env var * 🏭️ Rewrite Dockerfile to support multi-arch and cross-compilation * ➕ Add Docker CLI * ♻️ Move version numbers to their individual build stage for better caching * 🐞 Fix multi-arch support for krew * 📃 Update documentation * ➕ Add crane, ngrok, and skopeo * ➕ Add yq and switch versions to ARG instead of ENV Thanks @soulshake for the suggestion! * ⏫ Update kubeseal * 🐞 Fix kubeconfig download logic * ➖ Remove fftw (it's huge and doesn't bring much benefit to httping) * 🐞 Tiny typo fix in motd * ➕ Add k9s; rollback kubeseal version * 📃 Add info to install packages in motd * ✂️ Remove skopeo (it's rarely used and it's juse one 'apk add' away) * ➕ Add iputils so that ping runs without sudo * 🔑 Increase MaxAuthTries in SSH for folks with many keys * push on pr * auth on pr's * only latest if on default branch Co-authored-by: onlinejudge95 <onlinejudge95@gmail.com> Co-authored-by: Jérôme Petazzoni <jerome.petazzoni@gmail.com>
This commit is contained in:
11
.github/workflows/docker-build-and-push.yml
vendored
11
.github/workflows/docker-build-and-push.yml
vendored
@@ -53,14 +53,12 @@ jobs:
|
||||
${{ runner.os }}-buildx-
|
||||
-
|
||||
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: Login to GHCR
|
||||
if: github.event_name != 'pull_request'
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
registry: ghcr.io
|
||||
@@ -78,7 +76,8 @@ jobs:
|
||||
flavor: |
|
||||
latest=false
|
||||
tags: |
|
||||
type=raw,value=latest
|
||||
type=raw,value=latest,enable=${{ endsWith(github.ref, github.event.repository.default_branch) }}
|
||||
type=ref,event=pr,prefix=pr
|
||||
-
|
||||
# this will build the images, once per platform,
|
||||
# then push to both Docker Hub and GHCR
|
||||
@@ -87,12 +86,12 @@ jobs:
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
# had to remove linux/arm/v7 due to missing docker image
|
||||
platforms: linux/amd64,linux/arm64
|
||||
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
||||
builder: ${{ steps.buildx.outputs.name }}
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||
# don't push during a pull_request, only build
|
||||
push: ${{ github.event_name != 'pull_request' }}
|
||||
# for an approved pull_request, only push pr-specific tags
|
||||
push: true
|
||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||
-
|
||||
|
||||
Reference in New Issue
Block a user