-
Notifications
You must be signed in to change notification settings - Fork 1
50 lines (41 loc) · 1.14 KB
/
ibmi.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
name: IBM i build CI
on:
push:
branches: [ "main" ]
paths:
- 'ile/**'
pull_request:
branches: [ "main" ]
paths:
- 'ile/**'
env:
remote_build_dir: /home/${{ secrets.IBMI_USER }}/build/${{ github.sha }}
jobs:
build:
runs-on: ubuntu-latest
environment: OSSBUILD
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v4
with:
always-auth: true
node-version: 18
- run: npm i -g @ibm/ibmi-ci
- name: Get short SHA ID
run: |
echo "short_sha=$(echo ${{ github.sha }} | head -c 5)" >> $GITHUB_ENV
cat $GITHUB_ENV
- name: Deploy to IBM i
run: |
ici \
--rcwd "$remote_build_dir" \
--push "." \
--cmd "/QOpenSys/pkgs/bin/gmake -C ile BUILDLIB=MZNCI$short_sha uninstall all" \
--ignore --cl "dltlib MZNCI$short_sha" \
--rcwd ".." \
--ignore --cmd "rm -fr $remote_build_dir"
env:
IBMI_HOST: ${{ secrets.IBMI_HOST }}
IBMI_USER: ${{ secrets.IBMI_USER }}
IBMI_PASSWORD: ${{ secrets.IBMI_PASSWORD }}
IBMI_SSH_PORT: ${{ secrets.IBMI_SSH_PORT }}