Skip to content

Commit

Permalink
Move CI to GH actions (#219)
Browse files Browse the repository at this point in the history
  • Loading branch information
labkode authored Nov 16, 2023
1 parent c7f2111 commit a9b6cf5
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 66 deletions.
64 changes: 0 additions & 64 deletions .drone.yml

This file was deleted.

29 changes: 29 additions & 0 deletions .github/workflows/build-and-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: Build and Publish
on:
push:
branches:
- main
jobs:
build-and-publish:
name: Build and publish
runs-on: ubuntu-latest
container: cs3org/cs3apis-build:master
steps:
- name: Checkout
uses: actions/checkout@v4
- name: setup-ssh
env:
SSH_KEY: ${{ secrets.ssh_key}}
run: |
mkdir /root/.ssh
python3 -c "import os; file = open('/root/.ssh/id_rsa', 'w'); file.write(os.environ['SSH_KEY']); file.close()"
shasum /root/.ssh/id_rsa
chmod 400 /root/.ssh/id_rsa
stat /root/.ssh/id_rsa
touch /root/.ssh/known_hosts
chmod 400 /root/.ssh/known_hosts
ssh-keyscan -H github.com > /etc/ssh/ssh_known_hosts 2> /dev/null
cat /root/.ssh/id_rsa
- name: build-and-publish
run: cs3apis-build -git-ssh -push-go -push-js -push-node -push-python
15 changes: 15 additions & 0 deletions .github/workflows/build-only.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
name: Build only
on:
pull_request:
branches: [ "main" ]
jobs:
build:
name: Build only
runs-on: ubuntu-latest
container: cs3org/cs3apis-build:master
steps:
- name: Checkout
uses: actions/checkout@v4
- name: build-and-publish
run: cs3apis-build
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ pwd = $(shell pwd)
default: gen

gen:
docker run -v ${pwd}:/root/cs3apis hugo cs3apis-build
#docker run -v ${pwd}:/root/cs3apis cs3org/cs3apis cs3apis-build
echo ${pwd}
docker run -v ${pwd}:/root/cs3apis cs3org/cs3apis-build:master cs3apis-build

clean:
rm -rf build/
Expand Down

0 comments on commit a9b6cf5

Please sign in to comment.