Switch registry to scaleway
This commit is contained in:
parent
9ee92797e1
commit
f8245550d0
7 changed files with 29 additions and 4 deletions
|
@ -12,6 +12,10 @@ mailer:
|
||||||
acme_dns:
|
acme_dns:
|
||||||
host: acme.serguzim.me
|
host: acme.serguzim.me
|
||||||
|
|
||||||
|
container_registry:
|
||||||
|
public: "{{ opentofu.scaleway_registry_endpoint_public }}"
|
||||||
|
private: "{{ opentofu.scaleway_registry_endpoint_private }}"
|
||||||
|
|
||||||
|
|
||||||
services_path: /opt/services/
|
services_path: /opt/services/
|
||||||
|
|
||||||
|
|
|
@ -18,3 +18,11 @@ output "scaleway_service_keys" {
|
||||||
value = scaleway_iam_api_key.service_keys
|
value = scaleway_iam_api_key.service_keys
|
||||||
sensitive = true
|
sensitive = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
output "scaleway_registry_endpoint_public" {
|
||||||
|
value = scaleway_registry_namespace.public.endpoint
|
||||||
|
}
|
||||||
|
|
||||||
|
output "scaleway_registry_endpoint_private" {
|
||||||
|
value = scaleway_registry_namespace.private.endpoint
|
||||||
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
---
|
---
|
||||||
|
|
||||||
backup_image: registry.serguzim.me/services/backup
|
backup_image: "{{ (container_registry.public, 'services/backup') | path_join }}"
|
||||||
|
|
||||||
backup_svc:
|
backup_svc:
|
||||||
name: backup
|
name: backup
|
||||||
|
|
|
@ -24,7 +24,7 @@ caddy_env:
|
||||||
|
|
||||||
caddy_compose:
|
caddy_compose:
|
||||||
watchtower: false
|
watchtower: false
|
||||||
image: registry.serguzim.me/services/caddy:2-alpine
|
image: "{{ (container_registry.public, 'services/caddy:2-alpine') | path_join }}"
|
||||||
volumes:
|
volumes:
|
||||||
- "./config:/etc/caddy/"
|
- "./config:/etc/caddy/"
|
||||||
- data:/data
|
- data:/data
|
||||||
|
|
|
@ -4,7 +4,7 @@ x-common-elements:
|
||||||
&common-elements
|
&common-elements
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
image: registry.serguzim.me/services/healthcheck
|
image: "{{ (container_registry.public, 'services/healthcheck') | path_join }}"
|
||||||
restart: never
|
restart: never
|
||||||
env_file:
|
env_file:
|
||||||
- service.env
|
- service.env
|
||||||
|
|
|
@ -13,7 +13,7 @@ reitanlage_oranienburg_svc:
|
||||||
|
|
||||||
reitanlage_oranienburg_compose:
|
reitanlage_oranienburg_compose:
|
||||||
watchtower: false
|
watchtower: false
|
||||||
image: registry.serguzim.me/library/grav
|
image: "{{ (container_registry.public, 'library/grav') | path_join }}"
|
||||||
volumes:
|
volumes:
|
||||||
- data:/var/www/html/
|
- data:/var/www/html/
|
||||||
file:
|
file:
|
||||||
|
|
13
scaleway.tf
13
scaleway.tf
|
@ -79,3 +79,16 @@ resource "scaleway_iam_api_key" "service_keys" {
|
||||||
application_id = scaleway_iam_application.service_applications[each.key].id
|
application_id = scaleway_iam_application.service_applications[each.key].id
|
||||||
expires_at = time_rotating.rotate_after_a_year.rotation_rfc3339
|
expires_at = time_rotating.rotate_after_a_year.rotation_rfc3339
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
resource "scaleway_registry_namespace" "public" {
|
||||||
|
name = "public.serguzim.net"
|
||||||
|
description = "Public container registry for serguzim.net"
|
||||||
|
is_public = true
|
||||||
|
}
|
||||||
|
|
||||||
|
resource "scaleway_registry_namespace" "private" {
|
||||||
|
name = "private.serguzim.net"
|
||||||
|
description = "Private container registry for serguzim.net"
|
||||||
|
is_public = false
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue