-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'kosmos-io:main' into remove_unsed_file
- Loading branch information
Showing
34 changed files
with
2,266 additions
and
93 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,33 @@ | ||
name: Dev Images | ||
on: | ||
push: | ||
pull_request: | ||
workflow_dispatch: | ||
jobs: | ||
images: | ||
runs-on: ubuntu-latest | ||
permissions: write-all | ||
# not trigger on 'kosmos-io/kosmos' | ||
if: github.repository != 'kosmos-io/kosmos' | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up qemu | ||
uses: docker/setup-qemu-action@v2 | ||
- name: Login registry | ||
run: | | ||
echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin | ||
- name: 'Get Previous tag' | ||
id: previoustag | ||
uses: "WyriHaximus/github-action-get-previous-tag@v1" | ||
with: | ||
fallback: 1.0.0 | ||
- name: Push images | ||
env: | ||
ON_PLUGINS: true | ||
REGISTRY: ghcr.io/${{ github.repository_owner }}/${{ github.repository_name }} | ||
TAG: ${{ steps.previoustag.outputs.tag }} | ||
run: | | ||
make upload-images REGISTRY=${REGISTRY%?} VERSION=$TAG |
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
1,374 changes: 1,374 additions & 0 deletions
1,374
deploy/crds/kosmos.io_clusterpodconvertpolicies.yaml
Large diffs are not rendered by default.
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
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 |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -o errexit | ||
set -o nounset | ||
set -o pipefail | ||
|
||
# This script clean builds tmp files and go cache. | ||
# | ||
# Usage: | ||
# hack/clean.sh | ||
# Environments: | ||
# BUILD_PLATFORMS: platforms to build. You can set one or more platforms separated by comma. | ||
# e.g.: linux/amd64,linux/arm64 | ||
# Examples: | ||
# hack/clean.sh | ||
|
||
REPO_ROOT=$(dirname "${BASH_SOURCE[0]}")/.. | ||
source "${REPO_ROOT}/hack/util.sh" | ||
|
||
function clean() { | ||
echo "${REPO_ROOT}"/_tmp "${REPO_ROOT}"/_output | ||
rm -rf "${REPO_ROOT}"/_tmp "${REPO_ROOT}"/_output | ||
util::go_clean_cache | ||
} | ||
|
||
clean |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -o errexit | ||
set -o nounset | ||
set -o pipefail | ||
|
||
REPO_ROOT=$(dirname "${BASH_SOURCE[0]}")/.. | ||
|
||
# Show progress | ||
set -x | ||
|
||
# Orders are determined by two factors: | ||
# (1) Less Execution time item should be executed first. | ||
# (2) More likely to fail item should be executed first. | ||
bash "$REPO_ROOT/hack/verify-vendor.sh" | ||
bash "$REPO_ROOT/hack/verify-crds.sh" | ||
bash "$REPO_ROOT/hack/verify-codegen.sh" | ||
|
||
set +x |
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,46 @@ | ||
package v1alpha1 | ||
|
||
import ( | ||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" | ||
) | ||
|
||
// +genclient | ||
// +genclient:nonNamespaced | ||
// +kubebuilder:resource:scope="Cluster" | ||
// +kubebuilder:subresource:status | ||
// +kubebuilder:resource:shortName=pc | ||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object | ||
|
||
type ClusterPodConvertPolicy struct { | ||
metav1.TypeMeta `json:",inline"` | ||
metav1.ObjectMeta `json:"metadata,omitempty"` | ||
|
||
// Spec is the specification for the behaviour of the PodConvertPolicy. | ||
// +required | ||
Spec ClusterPodConvertPolicySpec `json:"spec"` | ||
} | ||
|
||
type ClusterPodConvertPolicySpec struct { | ||
// A label query over a set of resources. | ||
// If name is not empty, labelSelector will be ignored. | ||
// +required | ||
LabelSelector metav1.LabelSelector `json:"labelSelector"` | ||
|
||
// A label query over a set of resources. | ||
// If name is not empty, LeafNodeSelector will be ignored. | ||
// +option | ||
LeafNodeSelector *metav1.LabelSelector `json:"leafNodeSelector,omitempty"` | ||
|
||
// Converters are some converter for convert pod when pod synced from root cluster to leaf cluster | ||
// pod will use these converters to scheduled in leaf cluster | ||
// +optional | ||
Converters *Converters `json:"converters,omitempty"` | ||
} | ||
|
||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object | ||
|
||
type ClusterPodConvertPolicyList struct { | ||
metav1.TypeMeta `json:",inline"` | ||
metav1.ListMeta `json:"metadata"` | ||
Items []ClusterPodConvertPolicy `json:"items"` | ||
} |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.