Compare commits

...

11 Commits

Author SHA1 Message Date
Patrick Cleavelin 39779e611b save result of nix build in persistent volume
ci/woodpecker/tag/woodpecker Pipeline was successful Details
2023-07-30 14:09:36 -05:00
Patrick Cleavelin f4ae16ee7c just use docker instead of artifact
ci/woodpecker/tag/woodpecker Pipeline failed Details
2023-07-30 12:46:48 -05:00
Patrick Cleavelin e720556744 use correct tag
ci/woodpecker/tag/woodpecker Pipeline failed Details
2023-07-29 17:32:55 -05:00
Patrick Cleavelin 39d7113234 no docker, only nix
ci/woodpecker/push/woodpecker Pipeline failed Details
ci/woodpecker/tag/woodpecker Pipeline failed Details
2023-07-29 14:47:15 -05:00
Patrick Cleavelin 5d3bdd5249 Merge branch 'patrick/moar-test-ci' of https://git.spacegirl.nl/patrick/memejoin-rs into patrick/moar-test-ci
ci/woodpecker/push/woodpecker Pipeline failed Details
2023-07-29 14:10:46 -05:00
Patrick Cleavelin ca2d467a6d docker? 2023-07-29 13:36:21 -05:00
Patrick Cleavelin bdb0963558 will this actually work, probably not
ci/woodpecker/tag/woodpecker Pipeline failed Details
2023-07-29 13:16:21 -05:00
Patrick Cleavelin 3bdbce4985 will this actually work, probably not
ci/woodpecker/push/woodpecker Pipeline is pending Details
ci/woodpecker/tag/woodpecker Pipeline was successful Details
ci/woodpecker/deployment/woodpecker Pipeline failed Details
2023-07-29 12:46:34 -05:00
Patrick Cleavelin f3c5b2b164 update syntax
ci/woodpecker/push/woodpecker Pipeline failed Details
ci/woodpecker/deployment/woodpecker Pipeline failed Details
2023-07-28 15:25:10 -05:00
Patrick Cleavelin 907d0e9134 remove asdf
ci/woodpecker/push/woodpecker Pipeline failed Details
2023-07-28 15:22:37 -05:00
Patrick Cleavelin d935e8ea6d ci maybe?
ci/woodpecker/push/woodpecker Pipeline failed Details
2023-07-28 15:08:58 -05:00
2 changed files with 44 additions and 2 deletions

41
.woodpecker.yml Normal file
View File

@ -0,0 +1,41 @@
steps:
# build:
# image: alpine:edge
# commands:
# - apk add --no-cache git nix --repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing
# - nix build --extra-experimental-features nix-command --extra-experimental-features flakes .#default
build-docker-image:
image: alpine:edge
commands:
- apk add --no-cache git nix --repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing
- echo "system-features = nixos-test benchmark big-parallel uid-range kvm" > /etc/nix/nix.conf
- nix build --extra-experimental-features nix-command --extra-experimental-features flakes .#docker
- cp $(nix build --extra-experimental-features nix-command --extra-experimental-features flakes --print-out-paths .#docker) ./memejoin-rs.tar.gz
publish-image:
when:
event: tag
image: docker
secrets: [ forgejo_token ]
commands:
- docker login -u ${CI_REPO_OWNER} --password $FORGEJO_TOKEN git.spacegirl.nl
- docker image load --input memejoin-rs.tar.gz
- docker image tag memejoin-rs:${CI_COMMIT_TAG} git.spacegirl.nl/${CI_REPO}:${CI_COMMIT_TAG}
- docker image push git.spacegirl.nl/${CI_REPO}:${CI_COMMIT_TAG}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
# publish-image:
# when:
# event: tag
# image: git.spacegirl.nl/patrick/plugin-artifact:v0.1.1
# settings:
# tag: $CI_COMMIT_TAG
# user: patrick
# password:
# from_secret: forgejo_token
# repo: $CI_REPO
# image_tar: result
# volumes:
# - /var/run/docker.sock:/var/run/docker.sock

View File

@ -8,6 +8,7 @@
outputs = { self, nixpkgs, rust-overlay, flake-utils, ... }:
flake-utils.lib.eachDefaultSystem (system:
let
tag = "super_test";
overlays = [ (import rust-overlay) ];
pkgs = import nixpkgs {
inherit system overlays;
@ -45,8 +46,8 @@
packages = with pkgs; flake-utils.lib.flattenTree rec {
default = rustPlatform.buildRustPackage rec {
inherit tag;
name = "memejoin-rs";
version = "0.1.4_2-alpha";
src = self;
buildInputs = [ openssl.dev ];
nativeBuildInputs = [ local-rust pkg-config openssl openssl.dev cmake gcc libopus ];
@ -57,8 +58,8 @@
};
docker = dockerTools.buildImage {
inherit tag;
name = "memejoin-rs";
tag = "0.1.4_2-alpha";
copyToRoot = buildEnv {
name = "image-root";
paths = [ default cacert openssl openssl.dev ffmpeg libopus youtube-dl yt-dlp ];