mirror of
https://github.com/kennethreitz/bruce-operator.git
synced 2026-06-05 23:20:18 +00:00
registry service
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
|
||||
Usage:
|
||||
bruce-operator watch [--buildpacks|--apps]
|
||||
bruce-operator fetch [--buildpack=<buildpack>]
|
||||
bruce-operator fetch-buildpacks
|
||||
bruce-operator (-h | --help)
|
||||
|
||||
Options:
|
||||
@@ -26,7 +26,7 @@ def main():
|
||||
|
||||
watch(fork=True)
|
||||
|
||||
if args["fetch"]:
|
||||
if args["fetch-buildpacks"]:
|
||||
print("fetching")
|
||||
exit()
|
||||
|
||||
|
||||
@@ -146,13 +146,13 @@ class Operator:
|
||||
self.logger.info("Ensuring Buildpack volume resource...")
|
||||
kubectl(f"apply -f ./deploy/buildpacks-volume.yml -n {WATCH_NAMESPACE}")
|
||||
|
||||
def spawn_fetch_buildpack(self, buildpack_name):
|
||||
self.logger.info(f"Pretending to fetch {buildpack_name!r} buildpack!")
|
||||
self.spawn_self(f"fetch --buildpack={buildpack_name}", label="fetch")
|
||||
def spawn_fetch_buildpacks(self):
|
||||
for buildpack in self.installed_buildpacks:
|
||||
self.logger.info(f"Pretending to fetch {buildpack_name!r} buildpack!")
|
||||
self.spawn_self(f"fetch-buildpacks", label="fetch")
|
||||
|
||||
def fetch_buildpacks(self):
|
||||
for buildpack in self.installed_buildpacks:
|
||||
self.spawn_fetch_buildpack(buildpack["metadata"]["name"])
|
||||
|
||||
|
||||
def watch(self):
|
||||
self.logger.info("Pretending to watch...")
|
||||
|
||||
@@ -11,8 +11,9 @@ metadata:
|
||||
spec:
|
||||
clusterIP: None
|
||||
ports:
|
||||
- name: headless
|
||||
- name: registry-http
|
||||
port: 80
|
||||
nodePort: 80
|
||||
targetPort: 0
|
||||
selector:
|
||||
io.kompose.service: registry
|
||||
|
||||
Reference in New Issue
Block a user