Documentation
¶
Overview ¶
Copyright © 2020 Yale University
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
Copyright © 2020 Yale University ¶
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
Copyright © 2020 Yale University ¶
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
Copyright © 2020 Yale University ¶
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
Index ¶
- Variables
- func NewServer(config common.Config) error
- func TokenMiddleware(psk []byte, public map[string]string, h http.Handler) http.Handler
- type LogWriter
- type RepositoryCreateRequest
- type RepositoryResponse
- type RepositoryUpdateRequest
- type RepositoryUserCreateRequest
- type RepositoryUserResponse
- type RepositoryUserUpdateRequest
- type Tag
Constants ¶
This section is empty.
Variables ¶
var EcrAdminPolicy = iam.PolicyDocument{ Version: "2012-10-17", Statement: []iam.StatementEntry{ { Sid: "AllowActionsOnRepositoriesInSpaceAndOrg", Effect: "Allow", Action: []string{ "ecr:PutLifecyclePolicy", "ecr:PutImageTagMutability", "ecr:DescribeImageScanFindings", "ecr:GetDownloadUrlForLayer", "ecr:GetAuthorizationToken", "ecr:UploadLayerPart", "ecr:BatchDeleteImage", "ecr:ListImages", "ecr:DeleteLifecyclePolicy", "ecr:PutImage", "ecr:BatchGetImage", "ecr:CompleteLayerUpload", "ecr:DescribeImages", "ecr:DeleteRegistryPolicy", "ecr:InitiateLayerUpload", "ecr:BatchCheckLayerAvailability", }, Resource: []string{"*"}, Condition: iam.Condition{ "StringEqualsIgnoreCase": iam.ConditionStatement{ "aws:ResourceTag/Name": []string{"${aws:PrincipalTag/ResourceName}"}, "aws:ResourceTag/spinup:org": []string{"${aws:PrincipalTag/spinup:org}"}, "aws:ResourceTag/spinup:spaceid": []string{"${aws:PrincipalTag/spinup:spaceid}"}, }, }, }, { Sid: "AllowDockerLogin", Effect: "Allow", Action: []string{"ecr:GetAuthorizationToken"}, Resource: []string{"*"}, }, }, }
Functions ¶
Types ¶
type RepositoryCreateRequest ¶
type RepositoryCreateRequest struct { // Specify a custom KmsKeyId. This will also change the encryption type from // 'AES256' to 'KMS'. By default, when no encryption configuration is set or // the AES256 encryption type is used, Amazon ECR uses server-side encryption // with Amazon S3-managed encryption keys which encrypts your data at rest using // an AES-256 encryption algorithm. // Note: AWS KMS enforces a limit of 500 grants per CMK. As a result, there is // a limit of 500 Amazon ECR repositories that can be encrypted per CMK. KmsKeyId string // The setting that determines whether images are scanned after being pushed // to a repository. If set to true, images will be scanned after being pushed. // If this parameter is not specified, it will default to false and images will // not be scanned unless a scan is manually started with the StartImageScan // API. ScanOnPush string // The name to use for the repository. The repository name may be specified // on its own (such as nginx-web-app) or it can be prepended with a namespace // to group the repository into a category (such as project-a/nginx-web-app) RepositoryName string // List of additioal group ids that should have access to the repository Groups []string // Tags to apply to the repository Tags []*Tag }
RepositoryCreateRequest is the payload for creating an ECR repository
type RepositoryResponse ¶
type RepositoryResponse struct { CreatedAt time.Time EncryptionType string Groups []string KmsKeyId string ScanOnPush string ImageTagMutability string RegistryId string RepositoryArn string RepositoryName string RepositoryUri string Tags []*Tag }
RepositoryResponse is the response payload for repository operations
type RepositoryUpdateRequest ¶
RepositoryUpdateRequest is the payload for updating an ECR repository
type RepositoryUserCreateRequest ¶ added in v0.2.0
RepositoryUserCreateRequest is the request payload for creating a repository user
type RepositoryUserResponse ¶ added in v0.2.0
type RepositoryUserResponse struct { UserName string AccessKeys []*iam.AccessKeyMetadata `json:",omitempty"` AccessKey *iam.AccessKey `json:",omitempty"` DeletedAccessKeys []string `json:",omitempty"` Groups []string `json:",omitempty"` Tags []*Tag }
RepositoryUserResponse is the response payload for user operations
type RepositoryUserUpdateRequest ¶ added in v0.3.0
RepositoryUserUpdateRequest is the request payload for updating a user