Run Fabric CA and PostgreSQL with TLS enabled
#257
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # | |
| # Copyright IBM Corp. All Rights Reserved. | |
| # | |
| # SPDX-License-Identifier: Apache-2.0 | |
| # | |
| name: Tests | |
| on: | |
| push: | |
| branches: ["main"] | |
| pull_request: | |
| branches: ["main"] | |
| # Enable manual triggering | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| include: | |
| - inventory: "fabric-x" | |
| - inventory: "fabric-x-yugabyte" | |
| - inventory: "fabric-x-bin" | |
| - inventory: "fabric-x-cryptogen" | |
| fail-fast: false | |
| steps: | |
| # Checkout the repository code | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| # Install make | |
| - name: Install make | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y make | |
| # Install latest golang | |
| - name: Set up Go | |
| uses: actions/setup-go@v4 | |
| with: | |
| go-version: "stable" | |
| cache: true | |
| # Check that go is installed | |
| - name: Verify Go installation | |
| run: | | |
| go version | |
| echo "GOPATH: $GOPATH" | |
| echo "GOROOT: $GOROOT" | |
| # Install Python | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: "3.x" | |
| # Install the latest Ansible | |
| - name: Install Ansible | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install ansible ansible-core | |
| ansible --version | |
| # Install the required packages | |
| - name: Install all the required packages and collections | |
| env: | |
| CONTAINER_CLIENT: docker | |
| ANSIBLE_CACHE_PLUGIN: jsonfile | |
| ANSIBLE_CACHE_PLUGIN_CONNECTION: /tmp/ansible_fact_cache | |
| run: | | |
| pip install -r requirements.txt | |
| ansible-galaxy collection install -r requirements.yml | |
| make install install-prerequisites | |
| # Run the Hyperledger Fabric-X inventory | |
| - name: Test the (${{ matrix.inventory }}) inventory | |
| env: | |
| PROJECT_DIR: ${{ github.workspace }} | |
| CONTAINER_CLIENT: docker | |
| ANSIBLE_INVENTORY: ./examples/inventory/${{ matrix.inventory }}.yaml | |
| ANSIBLE_CACHE_PLUGIN: jsonfile | |
| ANSIBLE_CACHE_PLUGIN_CONNECTION: /tmp/ansible_fact_cache | |
| run: | | |
| ./ci/run_ci_test.sh |