first commit
This commit is contained in:
commit
aecdde7761
16
action.yaml
Normal file
16
action.yaml
Normal file
@ -0,0 +1,16 @@
|
||||
inputs:
|
||||
ssh_priv:
|
||||
description: SSH key to push to url
|
||||
required: true
|
||||
known_hosts:
|
||||
description: content of ~/.ssh/known_hosts
|
||||
required: true
|
||||
url:
|
||||
description: push destination
|
||||
required: true
|
||||
|
||||
runs:
|
||||
using: composite
|
||||
steps:
|
||||
- name: Checkout
|
||||
run: ${{ gitea.action_path }}/checkout.sh
|
9
mirror.sh
Executable file
9
mirror.sh
Executable file
@ -0,0 +1,9 @@
|
||||
#!/bin/bash -e
|
||||
|
||||
mkdir -p "$HOME/.ssh"
|
||||
echo "$INPUT_SSH_PRIV" > "$HOME/.ssh/id_ed25519"
|
||||
echo "$INPUT_KNOWN_HOSTS" > "$HOME/.ssh/known_hosts"
|
||||
|
||||
git remote set-url --push origin "$INPUT_URL"
|
||||
git checkout "$GITHUB_REF_NAME"
|
||||
git push origin "$GITHUB_REF_NAME"
|
Loading…
Reference in New Issue
Block a user