Skip to content

Commit

Permalink
build(workflows): test.yaml is included in containerize
Browse files Browse the repository at this point in the history
  • Loading branch information
GiugAles committed Jan 24, 2024
1 parent bc7f33d commit 463bc1b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 74 deletions.
25 changes: 8 additions & 17 deletions .github/workflows/containerize.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,12 @@ on:
- Dockerfile
workflow_dispatch:

# This should be consistent in the whole workflow
env:
# Maybe use https://stackoverflow.com/questions/67288526/github-actions-replace-character-in-string
# or https://github.com/orgs/community/discussions/45488
YGGDRASIL_VERSION: 0.0.0

jobs:
# https://stackoverflow.com/questions/67288526/github-actions-replace-character-in-string
# https://github.com/orgs/community/discussions/45488
set-vars:
runs-on: ubuntu-latest
outputs:
Expand All @@ -26,21 +25,10 @@ jobs:
- name: set values
id: gen_version
run: |
echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: character-replacement-test
run: |
REPO=$GITHUB_REPOSITORY
DB_NAME="${REPO//-/_}"
echo $DB_NAME
- name: Use the value
# this sets environment variables for this step
env:
VERSION: ${{ steps.gen_version.outputs.VERSION }}
run: |
echo "${VERSION}"
echo "VERSION=${GITHUB_REF_NAME////_}" >> $GITHUB_OUTPUT
build-and-test:
needs: [set-vars]
runs-on: ubuntu-latest
defaults:
run:
Expand All @@ -51,6 +39,7 @@ jobs:
# Tell scripts assume an non-interactive shell. This keeps logs clean
# in case of e.g. progress bars that would cause one line for each state, otherwise
TERM: dumb
YGGDRASIL_VERSION: "${{ needs.set-vars.outputs.VERSION }}"
ports:
- "8899:8080"
steps:
Expand Down Expand Up @@ -89,12 +78,14 @@ jobs:
if-no-files-found: error

containerize:
needs: build-and-test
needs: [set-vars, build-and-test]
environment: "containerized_debugging"
runs-on: ubuntu-latest
defaults:
run:
shell: bash
env:
YGGDRASIL_VERSION: "${{ needs.set-vars.outputs.VERSION }}"
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
57 changes: 0 additions & 57 deletions .github/workflows/test.yml

This file was deleted.

0 comments on commit 463bc1b

Please sign in to comment.