Skip to content

Commit

Permalink
Add initial GitHub Action to install from apt.tianon.xyz
Browse files Browse the repository at this point in the history
  • Loading branch information
tianon committed Sep 26, 2023
1 parent 8af2992 commit 62f5dfc
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/smoke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v3

- uses: ./ # drinking our own champagne

- name: Checkout debian-bin
uses: actions/checkout@v3 # https://github.com/tianon/debian-bin
with:
Expand Down
21 changes: 21 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: "Install Tianon's Moby Builds"
description: 'Install "docker" from builds by Tianon (https://apt.tianon.xyz/moby/)'
runs:
using: 'composite'
steps:
- run: |
# this assmues Ubuntu, and maps that to a rough corresponding Debian release to install packages from
debian="$(< /etc/debian_version)"
[[ "$debian" == */sid ]]
debian="${debian%/sid}" # "bookworm", etc.
sudo wget -O /etc/apt/sources.list.d/tianon-moby.sources "https://apt.tianon.xyz/moby/dists/$debian/tianon-moby.sources" # https://apt.tianon.xyz/moby/
sudo tee /etc/apt/preferences.d/tianon.pref <<-'EOPIN'
Package: *
Pin: release o=Tianon
Pin-Priority: 999
EOPIN
sudo apt-get update
sudo apt-get install -y --purge --auto-remove moby-cli moby-cli-plugin-buildx moby-engine
sudo systemctl enable --now docker.service
docker version
shell: 'bash -Eeuo pipefail -x {0}'

0 comments on commit 62f5dfc

Please sign in to comment.