Skip to content

Commit 50d3ed9

Browse files
committed
chore(base): use registry.drycc.cc replace docker.io
1 parent 6de09bb commit 50d3ed9

4 files changed

Lines changed: 32 additions & 19 deletions

File tree

.drone/drone.yml

Lines changed: 27 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,17 @@ platform:
99
steps:
1010
- name: publish
1111
commands:
12-
- echo $DOCKER_PASSWORD | docker login $DRYCC_REGISTRY --username $DOCKER_USERNAME --password-stdin
13-
- make publish clean
12+
- echo $CONTAINER_PASSWORD | docker login $DRYCC_REGISTRY --username $CONTAINER_USERNAME --password-stdin > /dev/null 2>&1
13+
- make clean publish clean
1414
environment:
1515
DEV_REGISTRY:
1616
from_secret: dev_registry
1717
DRYCC_REGISTRY:
1818
from_secret: drycc_registry
19-
DOCKER_USERNAME:
20-
from_secret: docker_username
21-
DOCKER_PASSWORD:
22-
from_secret: docker_password
19+
CONTAINER_USERNAME:
20+
from_secret: container_username
21+
CONTAINER_PASSWORD:
22+
from_secret: container_password
2323
when:
2424
event:
2525
- push
@@ -37,17 +37,17 @@ platform:
3737
steps:
3838
- name: publish
3939
commands:
40-
- echo $DOCKER_PASSWORD | docker login $DRYCC_REGISTRY --username $DOCKER_USERNAME --password-stdin
41-
- make publish clean
40+
- echo $CONTAINER_PASSWORD | docker login $DRYCC_REGISTRY --username $CONTAINER_USERNAME --password-stdin > /dev/null 2>&1
41+
- make clean publish clean
4242
environment:
4343
DEV_REGISTRY:
4444
from_secret: dev_registry
4545
DRYCC_REGISTRY:
4646
from_secret: drycc_registry
47-
DOCKER_USERNAME:
48-
from_secret: docker_username
49-
DOCKER_PASSWORD:
50-
from_secret: docker_password
47+
CONTAINER_USERNAME:
48+
from_secret: container_username
49+
CONTAINER_PASSWORD:
50+
from_secret: container_password
5151
when:
5252
event:
5353
- push
@@ -57,16 +57,29 @@ steps:
5757
kind: pipeline
5858
type: docker
5959
name: manifest
60+
image_pull_secrets:
61+
- container_pull_secrets
6062

6163
steps:
64+
- name: generate manifest
65+
image: registry.drycc.cc/drycc/python-dev
66+
pull: always
67+
commands:
68+
- sed -i "s/registry.drycc.cc/$${DRYCC_REGISTRY}/g" .drone/manifest.tmpl
69+
environment:
70+
DEV_REGISTRY:
71+
from_secret: dev_registry
72+
DRYCC_REGISTRY:
73+
from_secret: drycc_registry
74+
6275
- name: publish
6376
image: plugins/manifest
6477
settings:
6578
spec: .drone/manifest.tmpl
6679
username:
67-
from_secret: docker_username
80+
from_secret: container_username
6881
password:
69-
from_secret: docker_password
82+
from_secret: container_password
7083
environment:
7184
DEV_REGISTRY:
7285
from_secret: dev_registry

.drone/manifest.tmpl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
image: docker.io/drycc/base:bullseye
1+
image: registry.drycc.cc/drycc/base:bullseye
22
manifests:
33
-
4-
image: docker.io/drycc/base:bullseye-amd64
4+
image: registry.drycc.cc/drycc/base:bullseye-amd64
55
platform:
66
architecture: amd64
77
os: linux
88
-
9-
image: docker.io/drycc/base:bullseye-arm64
9+
image: registry.drycc.cc/drycc/base:bullseye-arm64
1010
platform:
1111
architecture: arm64
1212
os: linux

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
CODENAME ?= bullseye
2-
DEV_REGISTRY ?= docker.io
2+
DEV_REGISTRY ?= registry.drycc.cc
33
DRYCC_REGISTRY ?= ${DEV_REGISTRY}
44
IMAGE = "${DRYCC_REGISTRY}"/drycc/base:"${CODENAME}"-"$(shell dpkg --print-architecture)"
55
WORK_DIR = /workspace/"${CODENAME}"

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ A slimmed-down Debian-based container image used as the basis of [Drycc Workflow
99
Start your Dockerfile with this line:
1010

1111
```
12-
FROM docker.io/drycc/base:bullseye
12+
FROM registry.drycc.cc/drycc/base:bullseye
1313
```
1414

1515
There isn't a `:latest` tag, because each debian version is a tag.

0 commit comments

Comments
 (0)