Skip to content

Merge pull request #131 from francescotimperi/github-app #148

Merge pull request #131 from francescotimperi/github-app

Merge pull request #131 from francescotimperi/github-app #148

Workflow file for this run

# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
#
# Copyright 2021 Nuvolaris LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: Build Image
on:
push:
tags:
- '[0-9]*'
branches-ignore:
- '*'
jobs:
image:
name: Image
runs-on: ubuntu-latest
steps:
- name: Remove unnecessary files
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
- name: Checkout
uses: actions/checkout@v2
with:
submodules: recursive
- name: License
uses: apache/skywalking-eyes@main
- name: Make envfile
if: ${{ github.repository_owner != 'nuvolaris'}}
uses: SpicyPizza/create-envfile@v1.3
with:
envkey_MY_OPERATOR_IMAGE: ${{ secrets.MY_OPERATOR_IMAGE }}
envkey_GITHUB_TOKEN: ${{ secrets.GT_TOKEN }}
envkey_GITHUB_USER: ${{ secrets.GT_USER }}
file_name: .env
fail_on_empty: false
- name: Registry
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Setup
run: bash .github/cisetup.sh
- name: Kind
uses: helm/kind-action@v1.2.0
with:
cluster_name: nuvolaris
config: .github/kind.yaml
- name: Install
run: poetry install
- name: Tag
run: task image-tag
- name: BuildAndLoad
run: task build-and-load
- name: Ngrok
if: ${{ env.NGROK == 'on' }}
run: bash .github/debug-github-actions.sh
env:
NGROK_TOKEN: ${{ secrets.NGROK_TOKEN }}
USER_PASS: ${{ secrets.USER_PASS }}
- name: Wait
if: ${{ env.NGROK == 'on' }}
run: bash .github/wait.sh
- name: AddIngress
run: task kind:ingress
- name: Test
run: task test
- name: DockerLogin
if: ${{ github.repository_owner != 'nuvolaris'}}
run: task docker-login
- name: Buildx
uses: crazy-max/ghaction-docker-buildx@v1
with:
version: latest
- name: Image
run: task buildx-and-push