-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
6 changed files
with
84 additions
and
5 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
name: ci | ||
permissions: | ||
contents: read | ||
id-token: write | ||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
jobs: | ||
score-validate: | ||
runs-on: ubuntu-24.04 | ||
env: | ||
HUMCTL_VERSION: '*' | ||
steps: | ||
- name: checkout code | ||
uses: actions/checkout@v4 | ||
- name: install humctl | ||
uses: humanitec/setup-cli-action@v1 | ||
with: | ||
version: ${{ env.HUMCTL_VERSION }} | ||
- name: humctl score validate | ||
run: | | ||
scoreFiles=$(ls -d score/*/score*) | ||
for scoreFile in ${scoreFiles} | ||
do | ||
echo ${scoreFile} | ||
humctl score validate ${scoreFile} --strict --local | ||
done | ||
test-definition-echo: | ||
runs-on: ubuntu-24.04 | ||
env: | ||
HUMCTL_VERSION: '*' | ||
steps: | ||
- name: checkout code | ||
uses: actions/checkout@v4 | ||
- name: install humctl | ||
uses: humanitec/setup-cli-action@v1 | ||
with: | ||
version: ${{ env.HUMCTL_VERSION }} | ||
- name: test-definition echo-driver | ||
run: | | ||
resourceDefinitions=$(ls -d resource-definitions/echo-driver/*/*.yaml) | ||
for resourceDefinition in ${resourceDefinitions} | ||
do | ||
echo ${resourceDefinition} | ||
inputs=$(echo ${resourceDefinition} | sed "s,/,-,g") | ||
humctl resources test-definition ${resourceDefinition} --generate > ${inputs} | ||
sed -i 's/context.res.id: ""/context.res.id: "modules.test.externals.test"/g' ${inputs} | ||
sed -i 's/""/"test"/g' ${inputs} | ||
humctl resources test-definition ${resourceDefinition} --inputs ${inputs} | ||
done | ||
test-definition-template: | ||
runs-on: ubuntu-24.04 | ||
env: | ||
HUMCTL_VERSION: '*' | ||
steps: | ||
- name: checkout code | ||
uses: actions/checkout@v4 | ||
- name: install humctl | ||
uses: humanitec/setup-cli-action@v1 | ||
with: | ||
version: ${{ env.HUMCTL_VERSION }} | ||
- name: test-definition template-driver | ||
run: | | ||
resourceDefinitions=$(ls -d resource-definitions/template-driver/*/*.yaml) | ||
for resourceDefinition in ${resourceDefinitions} | ||
do | ||
echo ${resourceDefinition} | ||
if [ "${resourceDefinition}" != "resource-definitions/template-driver/ingress/ingress-traefik-multiple-routes.yaml" ]; then | ||
inputs=$(echo ${resourceDefinition} | sed "s,/,-,g") | ||
humctl resources test-definition ${resourceDefinition} --generate > ${inputs} | ||
sed -i 's/context.res.id: ""/context.res.id: "modules.test.externals.test"/g' ${inputs} | ||
sed -i 's/""/"test"/g' ${inputs} | ||
humctl resources test-definition ${resourceDefinition} --inputs ${inputs} | ||
fi | ||
done | ||
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
This example shows how to deploy multiple workloads within one deployment. | ||
|
||
Doing so requires a separate Score file per workload ([`score.example-service.yaml`](score.example-service.yaml) and [`score.another-service.yaml`](score.another-service.yaml)). The example also uses a Score extension file ([`score.humanitec.yaml`](score.humanitec.yaml)) to apply some common settings to both workloads. | ||
Doing so requires a separate Score file per workload ([`score.example-service.yaml`](score.example-service.yaml) and [`score.another-service.yaml`](score.another-service.yaml)). The example also uses a Score extension file ([`humanitec.score.yaml`](humanitec.score.yaml)) to apply some common settings to both workloads. | ||
|
||
The file [`deploy-config.yaml`](deploy-config.yaml) wraps all those files into a deploy configuration which can be passed in to `humctl` using the `--deploy-config` flag. See the [CLI documentation](https://developer.humanitec.com/platform-orchestrator/reference/cli-references/#score-integration) for details. |
This file contains 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
File renamed without changes.