-
Notifications
You must be signed in to change notification settings - Fork 90
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add download/push scripts for Ubuntu RTOS EKS-A image (#3034)
- Loading branch information
1 parent
6207b18
commit 21f30ee
Showing
6 changed files
with
143 additions
and
0 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,51 @@ | ||
|
||
|
||
|
||
########### DO NOT EDIT ############################# | ||
# To update call: make add-generated-help-block | ||
# This is added to help document dynamic targets and support shell autocompletion | ||
|
||
|
||
##@ Run in Docker Targets | ||
run-in-docker/all-attributions: ## Run `all-attributions` in docker builder container | ||
run-in-docker/all-attributions-checksums: ## Run `all-attributions-checksums` in docker builder container | ||
run-in-docker/all-checksums: ## Run `all-checksums` in docker builder container | ||
run-in-docker/attribution: ## Run `attribution` in docker builder container | ||
run-in-docker/attribution-checksums: ## Run `attribution-checksums` in docker builder container | ||
run-in-docker/binaries: ## Run `binaries` in docker builder container | ||
run-in-docker/checksums: ## Run `checksums` in docker builder container | ||
run-in-docker/clean: ## Run `clean` in docker builder container | ||
run-in-docker/clean-go-cache: ## Run `clean-go-cache` in docker builder container | ||
run-in-docker/validate-checksums: ## Run `validate-checksums` in docker builder container | ||
|
||
##@ Artifact Targets | ||
tarballs: ## Create tarballs by calling build/lib/simple_create_tarballs.sh unless SIMPLE_CREATE_TARBALLS=false, then tarballs must be defined in project Makefile | ||
s3-artifacts: # Prepare ARTIFACTS_PATH folder structure with tarballs/manifests/other items to be uploaded to s3 | ||
upload-artifacts: # Upload tarballs and other artifacts from ARTIFACTS_PATH to S3 | ||
|
||
##@ Clean Targets | ||
clean: ## Removes source and _output directory | ||
clean-go-cache: ## Removes the GOMODCACHE AND GOCACHE folders | ||
|
||
##@Fetch Binary Targets | ||
handle-dependencies: ## Download and extract TARs for each dependency listed in PROJECT_DEPENDENCIES | ||
|
||
##@ Helpers | ||
help: ## Display this help | ||
add-generated-help-block: ## Add or update generated help block to document project make file and support shell auto completion | ||
|
||
##@Update Helpers | ||
start-docker-builder: ## Start long lived builder base docker container | ||
stop-docker-builder: ## Clean up builder base docker container | ||
run-buildkit-and-registry: ## Run buildkitd and a local docker registry as containers | ||
stop-buildkit-and-registry: ## Stop the buildkitd and a local docker registry containers | ||
generate: ## Update UPSTREAM_PROJECTS.yaml | ||
update-go-mods: ## Update locally checked-in go sum to assist in vuln scanning | ||
update-vendor-for-dep-patch: ## After bumping dep in go.mod file, uses generic vendor update script or one provided from upstream project | ||
patch-for-dep-update: ## After bumping dep in go.mod file and updating vendor, generates patch | ||
create-ecr-repos: ## Create repos in ECR for project images for local testing | ||
|
||
##@ Build Targets | ||
build: ## Called via prow presubmit, calls `upload-artifacts` | ||
release: ## Called via prow postsubmit + release jobs, calls `upload-artifacts` | ||
########### END GENERATED ########################### |
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 @@ | ||
BASE_DIRECTORY:=$(abspath ../../../) | ||
GIT_TAG=non-existent | ||
|
||
REPO=ubuntu | ||
REPO_OWNER=canonical | ||
|
||
RTOS_BUCKET_NAME?= | ||
RTOS_IMAGE_DATE=$(shell cat RTOS_IMAGE_DATE) | ||
RELEASE_BRANCH=1-29 | ||
RTOS_SOURCE_URL=https://$(RTOS_BUCKET_NAME).s3.us-west-2.amazonaws.com/ubuntu/jammy/$(RTOS_IMAGE_DATE)/ubuntu-jammy-eks-anywhere-pro-realtime-minimal-amd64-eks-anywhere-$(RELEASE_BRANCH)-pro-realtime.raw.gz | ||
|
||
HAS_S3_ARTIFACTS=true | ||
SIMPLE_CREATE_BINARIES=false | ||
SIMPLE_CREATE_TARBALLS=false | ||
HAS_LICENSES=false | ||
IMAGE_NAMES= | ||
|
||
REPO_NO_CLONE=true | ||
GIT_CHECKOUT_TARGET=RTOS_IMAGE_DATE | ||
FAKE_GIT_REPO_TARGET=.git | ||
|
||
EXCLUDE_FROM_CHECKSUMS_BUILDSPEC=true | ||
EXCLUDE_FROM_UPGRADE_BUILDSPEC=true | ||
|
||
BUILD_TARGETS=upload-artifacts | ||
RELEASE_TARGETS=upload-artifacts | ||
|
||
include $(BASE_DIRECTORY)/Common.mk | ||
|
||
$(FAKE_GIT_REPO_TARGET): | ||
@git init | ||
@git remote add origin https://github.com/aws/eks-anywhere-build-tooling.git | ||
|
||
s3-artifacts: download-rtos-image | ||
|
||
.PHONY: download-rtos-image | ||
download-rtos-image: | ||
build/download_rtos_image.sh $(RTOS_SOURCE_URL) $(ARTIFACTS_PATH) | ||
|
||
|
||
########### DO NOT EDIT ############################# | ||
# To update call: make add-generated-help-block | ||
# This is added to help document dynamic targets and support shell autocompletion | ||
# Run make help for a formatted help block with all targets | ||
include Help.mk | ||
########### END GENERATED ########################### |
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 @@ | ||
20240414 |
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,30 @@ | ||
#!/usr/bin/env bash | ||
# Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. | ||
# | ||
# 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. | ||
|
||
|
||
set -x | ||
set -o errexit | ||
set -o pipefail | ||
|
||
RTOS_SOURCE_URL="${1?Specify first argument - source URL for the Ubuntu RTOS image}" | ||
ARTIFACTS_PATH="${2?Specify second argument - artifacts path}" | ||
|
||
function build::download::ubuntu::rtos::image(){ | ||
mkdir -p $ARTIFACTS_PATH | ||
filename=$(basename $RTOS_SOURCE_URL) | ||
curl -s $RTOS_SOURCE_URL -o $ARTIFACTS_PATH/ubuntu.gz | ||
} | ||
|
||
build::download::ubuntu::rtos::image |
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,9 @@ | ||
SHA256SUM | ||
SHA256SUM.sha256 | ||
SHA256SUM.sha512 | ||
SHA512SUM | ||
SHA512SUM.sha256 | ||
SHA512SUM.sha512 | ||
ubuntu.gz | ||
ubuntu.gz.sha256 | ||
ubuntu.gz.sha512 |
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