Skip to main content

Overview

Available

Deployed and supported. The fields and commands described here are stable within version v1alpha1.

Each tenant has a private OCI image registry, at <cluster>.registry.dev.stackngo.fr: the host carries the name of the cluster where your tenant lives (for example ovh-gra-0.registry.dev.stackngo.fr), the one sng config use-cluster selects. Each cluster has its own registry: there is no replication, an image is pushed to the registry of every cluster that deploys it, and an App only pulls from the registry of its own cluster. You push your applications' images there with docker, sng registry or any OCI client, and your App resources pull them from the same registry.

In short​

sng registry create web # 1. declare the repository (RegistryRepository manifest)
sng registry login # 2. docker uses your session, without a password
docker build -t ovh-gra-0.registry.dev.stackngo.fr/acme/web:1.0.0 .
docker push ovh-gra-0.registry.dev.stackngo.fr/acme/web:1.0.0

The image can then be addressed as ovh-gra-0.registry.dev.stackngo.fr/acme/web:1.0.0, where acme is your tenant.

The notions​

NotionWhat it isWhere it is described
Imageovh-gra-0.registry.dev.stackngo.fr/<tenant>/<repository>:<tag>Push and pull
RepositoryA name declared by a RegistryRepository manifest. Without a declaration, the registry refuses all access, even with all rightsRepositories and retention
RightsActions registry:pull, registry:push, registry:delete on repository/<repository>, granted by the tenant's policiesIdentity and access
Access keyA machine credential (RegistryAccessKey) limited to repositories and to pull / push, so that your App resources pull your private images; with ci: true, readable by an application of the tenant (a CI job, for example)Registry access keys
RetentionThe tags to keep (last N, N days, patterns); the rest is erased automaticallyRepositories and retention

Three ways to authenticate​

WhoUsernamePasswordTypical use
You, on your machinemanaged by sng registry loginyour tenant session, renewed automaticallydocker push, docker pull, sng registry
An access keyaccesskey/<tenant>/<name>generated and renewed by the platformimagePullSecrets of an App; environment variables of an App if ci: true
Nobodynonenonepull from a repository declared public: true

There is no registry-specific password: an sng session is enough, and its rights are those of your policies.

Who can do what​

The tenant's managed policies cover the common cases:

Policyregistry:pullregistry:pushregistry:delete
readonlyyesnono
readwriteyesyesyes
adminyesyesyes

For finer-grained settings (for example push on a single repository), write a policy with the resource repository/<repository>; see Identity and access. Declaring a repository or an access key goes through sng apply, hence through the deploy:write action.

Limitations of this version​

  • A repository is a single name under the tenant: acme/web is valid, acme/web/cache is not.
  • No web interface for the registry.
  • The registry does not scan images for vulnerabilities yet; sng registry build scans them on your machine with trivy (see sng registry build).
  • Immediate rotation of an access key is not available yet; periodic rotation is (Registry access keys).

See also​