Skip to content

Commit

Permalink
chore: add ssh key
Browse files Browse the repository at this point in the history
  • Loading branch information
benmezger committed Jan 14, 2024
1 parent 81ea6fe commit 69892b3
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ jobs:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: true
ssh-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Create non_root user
run: |
useradd nonroot && mkdir /home/nonroot && chown -R nonroot:nonroot /home/nonroot
Expand All @@ -44,24 +46,17 @@ jobs:
- name: Set source permissions
run: |
chown -R nonroot:nonroot .
- name: Clone sedspkg
run: |
git clone --depth 1 https://${{ secrets.GITLAB_SECRET_TOKEN }}@gitlab.com/benmezger/sedspkgs.git $pkgsdir && \
chown -R nonroot:nonroot $pkgsdir
- uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Build packages
run: |
ls -al ~/.ssh
sudo -u nonroot just makepkg_flags=$makepkg_flags all
- name: Show sedspkg diff
run: |
cd $pkgsdir
sudo -u nonroot git diff
- name: Commit and release
run: |
cd $pkgsdir
git config --global --add safe.directory $pkgsdir
git config --global user.email "[email protected]"
git config --global user.name "Ben Mezger"
git remote set-url origin https://oauth:${{ secrets.GITLAB_SECRET_TOKEN }}@gitlab.com/benmezger/sedspkgs.git
sudo -u nonroot just push-packages

0 comments on commit 69892b3

Please sign in to comment.