Merge "Add support registry.k8s.io docker registry service parameter"
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#
|
#
|
||||||
# Copyright (c) 2021 Wind River Systems, Inc.
|
# Copyright (c) 2021-2023 Wind River Systems, Inc.
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: Apache-2.0
|
# SPDX-License-Identifier: Apache-2.0
|
||||||
#
|
#
|
||||||
@@ -21,11 +21,13 @@
|
|||||||
# $3 - registry username (optional)
|
# $3 - registry username (optional)
|
||||||
# $4 - registry password (optional)
|
# $4 - registry password (optional)
|
||||||
#
|
#
|
||||||
# This script manipulates the parameters 'url', 'type' and 'auth-secret' of docker service.
|
# This script manipulates the parameters 'url', 'type' and 'auth-secret'
|
||||||
# Each one of these three parameters may exist inside the docker service sections docker-registry, elastic-registry,
|
# of docker service.Each one of these three parameters may exist inside
|
||||||
# gcr-registry, ghcr-registry, k8s-registry and quay-registry, so 18 parameters are manipulated in total.
|
# the docker service sections docker-registry, elastic-registry,
|
||||||
# Each section of service docker is referred also as registry in this script.
|
# gcr-registry, ghcr-registry, k8s-registry, quay-registry and
|
||||||
#
|
# registryk8s-registry so 19 parameters are manipulated in total.
|
||||||
|
# Each section of service docker is referred also as registry in this
|
||||||
|
# script.
|
||||||
|
|
||||||
if (( $# != 2 && $# != 4 )); then
|
if (( $# != 2 && $# != 4 )); then
|
||||||
echo "The format of the command: $0 registry_base_url registry_type [registry_username] [registry_password]"
|
echo "The format of the command: $0 registry_base_url registry_type [registry_username] [registry_password]"
|
||||||
@@ -51,6 +53,7 @@ REGISTRY_DICT['gcr-registry']='gcr.io'
|
|||||||
REGISTRY_DICT['ghcr-registry']='ghcr.io'
|
REGISTRY_DICT['ghcr-registry']='ghcr.io'
|
||||||
REGISTRY_DICT['k8s-registry']='k8s.gcr.io'
|
REGISTRY_DICT['k8s-registry']='k8s.gcr.io'
|
||||||
REGISTRY_DICT['quay-registry']='quay.io'
|
REGISTRY_DICT['quay-registry']='quay.io'
|
||||||
|
REGISTRY_DICT['registryk8s-registry']='registry.k8s.io'
|
||||||
|
|
||||||
source /etc/platform/openrc
|
source /etc/platform/openrc
|
||||||
|
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash -e
|
#!/bin/bash -e
|
||||||
#
|
#
|
||||||
# Copyright (c) 2021-2022 Wind River Systems, Inc.
|
# Copyright (c) 2021-2023 Wind River Systems, Inc.
|
||||||
#
|
#
|
||||||
# SPDX-License-Identifier: Apache-2.0
|
# SPDX-License-Identifier: Apache-2.0
|
||||||
#
|
#
|
||||||
@@ -42,7 +42,7 @@ fi
|
|||||||
# Constant variables
|
# Constant variables
|
||||||
NEW_CREDS="username:${usr} password:${pw}"
|
NEW_CREDS="username:${usr} password:${pw}"
|
||||||
REGISTRY_LIST="docker-registry quay-registry elastic-registry gcr-registry \
|
REGISTRY_LIST="docker-registry quay-registry elastic-registry gcr-registry \
|
||||||
k8s-registry ghcr-registry"
|
k8s-registry ghcr-registry registryk8s-registry"
|
||||||
CENTRAL_REGISTRY_URL="registry.central"
|
CENTRAL_REGISTRY_URL="registry.central"
|
||||||
|
|
||||||
echo
|
echo
|
||||||
|
Reference in New Issue
Block a user