Try new stages feature

This commit is contained in:
Gerald Pinder
2024-05-02 16:03:35 -04:00
parent 43213f6022
commit c344efc32d
5 changed files with 53 additions and 1 deletions

View File

@@ -15,7 +15,7 @@ build-image:
stage: build stage: build
interruptible: true interruptible: true
image: image:
name: ghcr.io/blue-build/cli:main name: ghcr.io/blue-build/cli:108-feat-allow-adding-stages-to-run-builds-for-things-like-compiled-programs
entrypoint: [""] entrypoint: [""]
services: services:
- docker:dind - docker:dind

View File

@@ -0,0 +1,17 @@
#!/usr/bin/env bash
set -euo pipefail
apt-get update && apt-get install -y git
mkdir -p /src/
cd /src/
git clone https://github.com/helix-editor/helix.git
cd helix
RUSTFLAGS="-C target-feature=-crt-static"
cargo install --path helix-term --locked
mkdir -p /out/
mv $CARGO_HOME/bin/hx /out/

View File

@@ -0,0 +1,15 @@
stages:
- name: blue-build
image: rust
modules:
- type: containerfile
snippets:
- |
RUN cargo install blue-build --all-features --target x86_64-unknown-linux-gnu \
&& mkdir -p /out/ \
&& mv $CARGO_HOME/bin/bluebuild /out/bluebuild
modules:
- type: copy
from: blue-build
src: /out/bluebuild
dest: /usr/bin/bluebuild

15
recipes/common/helix.yml Normal file
View File

@@ -0,0 +1,15 @@
stages:
- name: helix
image: rust
shell:
- bash
- -c
modules:
- type: script
scripts:
- install-helix.sh
modules:
- type: copy
from: helix
src: /out/helix
dest: /usr/bin/

View File

@@ -2,5 +2,10 @@ name: jp-desktop
base-image: ghcr.io/ublue-os/bazzite-nvidia base-image: ghcr.io/ublue-os/bazzite-nvidia
image-version: 40 image-version: 40
description: The image of Wunker OS for JP's desktop gaming. description: The image of Wunker OS for JP's desktop gaming.
stages:
- from-file: common/bluebuild.yml
- from-file: common/helix.yml
modules: modules:
- from-file: common/jp-desktop.yml - from-file: common/jp-desktop.yml
- from-file: common/bluebuild.yml
- from-file: common/helix.yml