Skip to content

Commit

Permalink
Refactor optional images
Browse files Browse the repository at this point in the history
  • Loading branch information
gbraad authored Jan 7, 2025
1 parent 7c4ed50 commit 7e8373d
Show file tree
Hide file tree
Showing 5 changed files with 104 additions and 4 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/build-container-coder.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: build container - coder
run-name: building container - coder
on:
schedule:
- cron: "0 0 1 * *"
workflow_dispatch:
jobs:
build:
permissions:
contents: read
packages: write
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-24.04
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Run podman build - coder
run: podman build -t ghcr.io/gbraad-devenv/fedora/coder:41 -f containers/Containerfile-coder .
- name: Push image to ghcr.io - coder
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/coder:41
24 changes: 24 additions & 0 deletions .github/workflows/build-container-rdesktop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: build container - rdeskop
run-name: building container - rdesktop
on:
schedule:
- cron: "0 0 1 * *"
workflow_dispatch:
jobs:
build:
permissions:
contents: read
packages: write
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-24.04
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Run podman build - rdesktop
run: podman build -t ghcr.io/gbraad-devenv/fedora/rdesktop:41 -f containers/Containerfile-rdesktop .
- name: Push image to ghcr.io - rdesktop
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/rdesktop:41
24 changes: 24 additions & 0 deletions .github/workflows/build-container-toolbox.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: build container - toolbox
run-name: building container - toolbox
on:
schedule:
- cron: "0 0 1 * *"
workflow_dispatch:
jobs:
build:
permissions:
contents: read
packages: write
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-24.04
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Run podman build - toolbox
run: podman build -t ghcr.io/gbraad-devenv/fedora/toolbox:41 -f containers/Containerfile-toolbox .
- name: Push image to ghcr.io - toolbox
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/toolbox:41
4 changes: 0 additions & 4 deletions .github/workflows/build-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ jobs:
run: podman build -t ghcr.io/gbraad-devenv/fedora/systemd:41 -f containers/Containerfile-systemd .
- name: Run podman build - rdesktop
run: podman build -t ghcr.io/gbraad-devenv/fedora/rdesktop:41 -f containers/Containerfile-rdesktop .
- name: Run podman build - coder
run: podman build -t ghcr.io/gbraad-devenv/fedora/coder:41 -f containers/Containerfile-coder .
- name: Push image to ghcr.io - base
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/base:41
- name: Push image to ghcr.io - dotfiles
Expand All @@ -36,5 +34,3 @@ jobs:
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/systemd:41
- name: Push image to ghcr.io - rdesktop
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/rdesktop:41
- name: Push image to ghcr.io - coder
run: podman push --creds=${{ github.actor }}:${{ secrets.GITHUB_TOKEN }} ghcr.io/gbraad-devenv/fedora/coder:41
32 changes: 32 additions & 0 deletions .github/workflows/tailscale-coder.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: tailscale-coder
on:
workflow_dispatch:

jobs:
coder-test:
runs-on: ubuntu-24.04

steps:
- name: Run system container with `podman`
run: |
podman run -d --name coder ghcr.io/gbraad-devenv/fedora/coder:41
- name: Tailscale setup (root)
run: |
until podman exec coder tailscale up --auth-key ${TAILSCALE_AUTHKEY}
do
sleep 0.1
done
podman exec coder tailscale set --ssh
podman exec coder tailscale set --hostname github-${HOSTNAME}
env:
TAILSCALE_AUTHKEY: ${{ secrets.TAILSCALE_AUTHKEY}}
- name: Hang around
run: |
until podman exec coder systemctl is-active code-server@gbraad
do
sleep 1
done
IP=`podman exec coder tailscale ip -4`
echo "Open in your web browser: https://${IP}:8080"
podman exec coder cat ~gbraad/.config/code-server/config.yaml
sleep infinity

0 comments on commit 7e8373d

Please sign in to comment.