dotfiles
- 28 commits
- 1 branch
- 0 tags
- updated
- CI 1/1
feat: update gitea mirror workflow
SignedGitea couldn't verify the signature.
Showing 1 changed file with 18 additions and 2 deletions.
.tangled/workflows/mirror.yaml
+18 −2
@@ -8,6 +8,9 @@ when:8899engine: "nixery"101011dependencies:12 nixpkgs:13 - openssh1114steps:1215 # spindle clones one commit deep (depth: 0 means 1 too), and the mirrors1316 # need the whole history. this also points origin/main at the newest main,@@ -22,7 +25,20 @@ steps:2225 set -euo pipefail2326 git push --force "https://x-access-token:${GH_MIRROR_TOKEN}@github.com/daniel-daum/dotfiles.git" refs/remotes/origin/main:refs/heads/main242728 # over ssh to git-ssh, which skips cloudflare. https to git.danieldaum.net29 # goes through it, and its bot protection blocks spindle at random2530 - name: "Mirror to Gitea"2631 command: |27 set -euo pipefail28 git push --force "https://daniel-daum:${GITEA_MIRROR_TOKEN}@git.danieldaum.net/daniel-daum/dotfiles.git" refs/remotes/origin/main:refs/heads/main32 set -euo pipefail33 34 # ssh refuses to run without a passwd entry, and nixery images have none35 mkdir -p /etc36 [ -e /etc/passwd ] || echo "root:x:0:0:root:${HOME}:/bin/bash" > /etc/passwd37 38 mkdir -p "${HOME}/.ssh"39 printf '%s\n' "${GITEA_MIRROR_KEY}" > "${HOME}/.ssh/gitea"40 chmod 600 "${HOME}/.ssh/gitea"41 ssh-keyscan -p 2222 git-ssh.danieldaum.net > "${HOME}/.ssh/known_hosts"42 43 export GIT_SSH_COMMAND="ssh -i ${HOME}/.ssh/gitea -o IdentitiesOnly=yes -o UserKnownHostsFile=${HOME}/.ssh/known_hosts"44 git push --force "ssh://git@git-ssh.danieldaum.net:2222/daniel-daum/${TANGLED_REPO_NAME}.git" refs/remotes/origin/main:refs/heads/main