Skip to content

Commit

Permalink
Merge pull request #62 from hubblo-org/ci/#43-add-cargo-test-all-in-ci
Browse files Browse the repository at this point in the history
ci: ci/#43 add cargo test all in ci
see #43
  • Loading branch information
bpetit authored Jan 27, 2021
2 parents aac71b0 + 20a4fbb commit b521a85
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: build_and_test

on:
push:
branches: [ main, dev ]
pull_request:
branches: [ main, dev ]

env:
CARGO_TERM_COLOR: always

jobs:
build:
name: build_and_test_x86_64
runs-on: ubuntu-latest
steps:
- name: Install dependencies (awxkit)
uses: actions/setup-python@v2
with:
python-version: '3.8.5'
- name: Install python requirements (awxkit)
run: |
python -m pip install --upgrade pip
pip install awxkit
#- name: Install jq
# run: |
# sudo apt install jq -y
- name: Log on AWX
id: login
run: |
export AWX_TOKEN=$(awx --conf.host ${{ secrets.AWX_HOST }} --conf.username ${{ secrets.AWX_USERNAME }} --conf.password ${{ secrets.AWX_PASSWORD }} login | jq .token | tr -d '"')
echo "::set-output name=awx_token::${AWX_TOKEN}"
- name: Launch job
id: launch
run: |
awx --conf.token ${{ steps.login.outputs.awx_token }} --conf.host https://cd.hubblo.org job_templates launch --extra_vars="{\"github_repository\":\"${GITHUB_REPOSITORY}\",\"github_actor\":\"${GITHUB_ACTOR}\",\"github_workflow\":\"${GITHUB_WORKFLOW}\",\"github_workspace\":\"${GITHUB_WORKSPACE}\",\"github_event_name\":\"${GITHUB_EVENT_NAME}\",\"github_event_path\":\"${GITHUB_EVENT_PATH}\",\"github_sha\":\"${GITHUB_SHA}\",\"github_ref\":\"${GITHUB_REF}\",\"github_head_ref\":\"${GITHUB_HEAD_REF}\",\"github_base_ref\":\"${GITHUB_BASE_REF}\",\"github_server_url\":\"${GITHUB_SERVER_URL}\"}" 9 --monitor

0 comments on commit b521a85

Please sign in to comment.