-
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.
* #70 remove garage project * update org vars * revert change * cleanup * cleanup * cleanup * tmp test * add yamllint * standardization, remove doc start * add default yamllint config * make linter reusable * cleanup
- Loading branch information
Showing
17 changed files
with
129 additions
and
227 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,11 @@ | ||
--- | ||
|
||
# Extends the default yamllint config by adjusting some options. | ||
extends: default | ||
|
||
rules: | ||
comments-indentation: disable | ||
line-length: | ||
level: warning | ||
allow-non-breakable-inline-mappings: true | ||
truthy: disable |
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,3 @@ | ||
--- | ||
|
||
name: 'add labels to issue' | ||
|
||
on: | ||
|
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,3 @@ | ||
--- | ||
|
||
name: 'add to project' | ||
|
||
on: | ||
|
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,3 @@ | ||
--- | ||
|
||
name: 'dependabot approve and merge' | ||
|
||
on: | ||
|
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
166 changes: 82 additions & 84 deletions
166
.github/workflows/docker-push-containers-to-dockerhub-and-ecr.yaml
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,96 +1,94 @@ | ||
--- | ||
|
||
name: 'docker-push-containers-to-dockerhub-and-ecr' | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
build-options: | ||
description: Additional options to pass to docker buildx build | ||
type: string | ||
context: | ||
default: "." | ||
description: Context (directory) of the docker build process | ||
type: string | ||
docker-image-repository: | ||
description: Docker repository (e.g. senzing/senzingapi-runtime) | ||
required: true | ||
type: string | ||
docker-registry-server: | ||
default: docker.io | ||
description: Docker registry server | ||
type: string | ||
ecr-image-repository: | ||
description: ECR repository (e.g. senzing/senzingapi-runtime) | ||
required: true | ||
type: string | ||
image-tag: | ||
default: latest | ||
description: Docker image tag | ||
type: string | ||
platforms: | ||
default: "linux/amd64" | ||
type: string | ||
workflow_call: | ||
inputs: | ||
build-options: | ||
description: Additional options to pass to docker buildx build | ||
type: string | ||
context: | ||
default: "." | ||
description: Context (directory) of the docker build process | ||
type: string | ||
docker-image-repository: | ||
description: Docker repository (e.g. senzing/senzingapi-runtime) | ||
required: true | ||
type: string | ||
docker-registry-server: | ||
default: docker.io | ||
description: Docker registry server | ||
type: string | ||
ecr-image-repository: | ||
description: ECR repository (e.g. senzing/senzingapi-runtime) | ||
required: true | ||
type: string | ||
image-tag: | ||
default: latest | ||
description: Docker image tag | ||
type: string | ||
platforms: | ||
default: "linux/amd64" | ||
type: string | ||
|
||
secrets: | ||
AWS_DOCKER_ACCOUNT_ID: | ||
required: true | ||
DOCKERHUB_ACCESS_TOKEN: | ||
required: true | ||
DOCKERHUB_USERNAME: | ||
required: true | ||
secrets: | ||
AWS_DOCKER_ACCOUNT_ID: | ||
required: true | ||
DOCKERHUB_ACCESS_TOKEN: | ||
required: true | ||
DOCKERHUB_USERNAME: | ||
required: true | ||
|
||
jobs: | ||
docker-push-containers-to-dockerhub-and-ecr: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write # This is required for requesting the JWT | ||
contents: read # This is required for actions/checkout | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: '0' | ||
submodules: recursive | ||
docker-push-containers-to-dockerhub-and-ecr: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
id-token: write # This is required for requesting the JWT | ||
contents: read # This is required for actions/checkout | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: '0' | ||
submodules: recursive | ||
|
||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v3 | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Login to Docker Hub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }} | ||
- name: Login to Docker Hub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }} | ||
|
||
- name: Configure AWS Credentials | ||
uses: aws-actions/configure-aws-credentials@v4 | ||
env: | ||
AWS_REGION: "us-east-1" | ||
with: | ||
role-to-assume: arn:aws:iam::${{ secrets.AWS_DOCKER_ACCOUNT_ID }}:role/github-actions-ecr-push | ||
role-session-name: GitHub_to_AWS_via_FederatedOIDC | ||
aws-region: ${{ env.AWS_REGION }} | ||
- name: Configure AWS Credentials | ||
uses: aws-actions/configure-aws-credentials@v4 | ||
env: | ||
AWS_REGION: "us-east-1" | ||
with: | ||
role-to-assume: arn:aws:iam::${{ secrets.AWS_DOCKER_ACCOUNT_ID }}:role/github-actions-ecr-push | ||
role-session-name: GitHub_to_AWS_via_FederatedOIDC | ||
aws-region: ${{ env.AWS_REGION }} | ||
|
||
- name: Login to Amazon ECR Public | ||
id: login-ecr-public | ||
uses: aws-actions/amazon-ecr-login@v2 | ||
with: | ||
registry-type: public | ||
- name: Login to Amazon ECR Public | ||
id: login-ecr-public | ||
uses: aws-actions/amazon-ecr-login@v2 | ||
with: | ||
registry-type: public | ||
|
||
- name: Docker build images | ||
shell: bash | ||
env: | ||
ECR_REGISTRY_SERVER: ${{ steps.login-ecr-public.outputs.registry }} | ||
run: | | ||
docker buildx build \ | ||
--push \ | ||
--platform ${{ inputs.platforms }} \ | ||
--tag ${{ inputs.docker-registry-server }}/${{ inputs.docker-image-repository }}:${{ inputs.image-tag }} \ | ||
--tag ${{ inputs.docker-registry-server }}/${{ inputs.docker-image-repository }}:latest \ | ||
--tag ${{ env.ECR_REGISTRY_SERVER }}/${{ inputs.ecr-image-repository }}:${{ inputs.image-tag }} \ | ||
--tag ${{ env.ECR_REGISTRY_SERVER }}/${{ inputs.ecr-image-repository }}:latest \ | ||
${{ inputs.build-options }} \ | ||
${{ inputs.context }} | ||
- name: Docker build images | ||
shell: bash | ||
env: | ||
ECR_REGISTRY_SERVER: ${{ steps.login-ecr-public.outputs.registry }} | ||
run: | | ||
docker buildx build \ | ||
--push \ | ||
--platform ${{ inputs.platforms }} \ | ||
--tag ${{ inputs.docker-registry-server }}/${{ inputs.docker-image-repository }}:${{ inputs.image-tag }} \ | ||
--tag ${{ inputs.docker-registry-server }}/${{ inputs.docker-image-repository }}:latest \ | ||
--tag ${{ env.ECR_REGISTRY_SERVER }}/${{ inputs.ecr-image-repository }}:${{ inputs.image-tag }} \ | ||
--tag ${{ env.ECR_REGISTRY_SERVER }}/${{ inputs.ecr-image-repository }}:latest \ | ||
${{ inputs.build-options }} \ | ||
${{ inputs.context }} |
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,3 @@ | ||
--- | ||
|
||
name: 'gofmt' | ||
|
||
on: [workflow_call] | ||
|
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
name: 'lint repo' | ||
|
||
on: | ||
push: | ||
branches-ignore: [main] | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
lint-code-base: | ||
uses: senzing-factory/build-resources/.github/workflows/linter.yaml@main |
Oops, something went wrong.