lets try another avenue...
Some checks failed
Test action / Print hello world (push) Failing after 13s

This commit is contained in:
Chris Kruining 2025-09-04 13:47:02 +02:00
parent 33f9a7fbd8
commit b8e43fedba
No known key found for this signature in database
GPG key ID: EB894A3560CCCAD2
3 changed files with 23 additions and 28 deletions

View file

@ -24,36 +24,28 @@ jobs:
- name: Prepare podman
run: |
# configure container policy to accept insecure registry
nix-env -iA nixpkgs.podman nixpkgs.kmod
nix-env -iA nixpkgs.podman
# configure container policy to accept insecure registry
mkdir -p ~/.config/containers
echo '{ "default": [ {"type":"insecureAcceptAnything"} ] }' > ~/.config/containers/policy.json
# ensure all required directories exist with proper permissions
mkdir -p /tmp/podman /var/tmp ~/.local/share/containers
chmod 755 /tmp/podman /var/tmp || true
# set multiple environment variables for skopeo temporary directories
export TMPDIR=/tmp/podman
export TMP=/tmp/podman
export TEMP=/tmp/podman
export XDG_RUNTIME_DIR=/tmp/podman
modprobe fuse
- name: Log into registry
run: |
podman login --username "${{ forge.actor }}" --password "${{ forge.token }}" ${{ env.registry }}
- name: Build image
run: >-
podman build
-t ${{ env.registry }}/${{ env.owner }}/${{ env.image }}:${{ env.tag }}
-f Dockerfile.default
modules/nixos/services/development/forgejo
env:
DOCKER_BUILDKIT: 1
run: nix-build modules/nixos/services/development/forgejo/runners/default.nix
# run: >-
# podman build
# -t ${{ env.registry }}/${{ env.owner }}/${{ env.image }}:${{ env.tag }}
# -f Dockerfile.default
# modules/nixos/services/development/forgejo
- name: __DEBUG__
run: |
ls -al result
podman load < result
- name: Push image
run: |

View file

@ -1,8 +0,0 @@
FROM docker.io/nixos/nix:latest
RUN nix-env -iA nixpkgs.nodejs_24 nixpkgs.podman
RUN echo "experimental-features = nix-command flakes pipe-operators" >> /etc/nix/nix.conf
RUN echo '{ "default": [ {"type":"insecureAcceptAnything"} ] }' >> /etc/containers/policy.json
CMD ["/bin/bash"]

View file

@ -0,0 +1,11 @@
{
pkgs ? import <nixpkgs> {},
pkgs_linux ? import <nixpkgs> { system = "x86_64-linux"; },
}:
pkgs.dockerTools.buildImage {
name = "default";
config = {
Cmd = [ "${pkgs_linux.hello}/bin/hello" ];
};
}