mirror of
https://github.com/ansible/awx-operator.git
synced 2026-03-26 21:33:14 +00:00
Intial GH Actions
This commit is contained in:
41
.github/workflows/ci.yaml
vendored
Normal file
41
.github/workflows/ci.yaml
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
---
|
||||
|
||||
name: CI
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: [devel]
|
||||
|
||||
jobs:
|
||||
pull_request:
|
||||
runs-on: ubuntu-18.04
|
||||
name: pull_request
|
||||
env:
|
||||
DOCKER_API_VERSION: "1.38"
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: "3.8"
|
||||
|
||||
- name: Install Dependencies
|
||||
run: |
|
||||
pip install \
|
||||
molecule \
|
||||
molecule-docker \
|
||||
yamllint \
|
||||
ansible-lint \
|
||||
openshift \
|
||||
jmespath \
|
||||
ansible
|
||||
|
||||
- name: Install Collections
|
||||
run: |
|
||||
ansible-galaxy collection install community.kubernetes operator_sdk.util
|
||||
|
||||
- name: Run Molecule
|
||||
env:
|
||||
MOLECULE_VERBOSITY: 3
|
||||
run: |
|
||||
molecule test -s test-local
|
||||
34
.github/workflows/release.yaml
vendored
Normal file
34
.github/workflows/release.yaml
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
---
|
||||
|
||||
name: Release
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [devel]
|
||||
|
||||
jobs:
|
||||
release:
|
||||
runs-on: ubuntu-18.04
|
||||
name: release
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install Operator-SDK
|
||||
run: |
|
||||
mkdir -p $GITHUB_WORKSPACE/bin
|
||||
wget -O $GITHUB_WORKSPACE/bin/operator-sdk https://github.com/operator-framework/operator-sdk/releases/download/v0.19.4/operator-sdk-v0.19.4-x86_64-linux-gnu
|
||||
chmod +x $GITHUB_WORKSPACE/bin/operator-sdk
|
||||
echo "$GITHUB_WORKSPACE/bin" >> $GITHUB_PATH
|
||||
|
||||
- name: Build Image
|
||||
run: |
|
||||
operator-sdk build awx-operator:devel
|
||||
|
||||
- name: Push To Quay
|
||||
uses: redhat-actions/push-to-registry@v2.1.1
|
||||
with:
|
||||
image: awx-operator
|
||||
tags: devel
|
||||
registry: quay.io/ansible/
|
||||
username: ${{ secrets.QUAY_USERNAME }}
|
||||
password: ${{ secrets.QUAY_TOKEN }}
|
||||
Reference in New Issue
Block a user