diff --git a/.gitmodules b/.gitmodules index 4169b71..07c9880 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,11 +1,11 @@ [submodule "plugins/dynamic_challenges_mod"] -path = plugins/dynamic_challenges_mod -url = https://github.com/sigpwny/ctfd-dynamic-challenges-mod + path = plugins/dynamic_challenges_mod + url = https://github.com/sigpwny/ctfd-dynamic-challenges-mod [submodule "plugins/kubectf-plugin"] -path = plugins/kubectf-plugin -url = https://github.com/ctfpilot/ctfd-kubectf-plugin + path = plugins/kubectf-plugin + url = https://github.com/ctfpilot/ctfd-kubectf-plugin [submodule "plugins/ctfd-discord-webhook-plugin"] -path = plugins/ctfd-discord-webhook-plugin -url = https://github.com/sigpwny/ctfd-discord-webhook-plugin + path = plugins/ctfd-discord-webhook-plugin + url = https://github.com/sigpwny/ctfd-discord-webhook-plugin diff --git a/README.md b/README.md index 20b5e40..eb02440 100644 --- a/README.md +++ b/README.md @@ -15,15 +15,25 @@ This configuration currently runs on CTFd version `3.7.7`. 2. If the plugin is a Github repo, add it as a submodule: ```bash git submodule add plugins/ - ``` + ``` 3. If the plugin is not a Github repo, copy the plugin files into the new directory. 4. Add the plugin to the `plugins/__init__.py` file: -5. ```python + ```python from . import ``` The Dockerfile will automatically copy all plugins from the `plugins` directory into the Docker image. +### How to add a new CTFd theme + +If the theme is a Github repo, add it as a submodule: + +```bash +git submodule add themes/ +``` + +If the theme is not a Github repo, copy the theme files into the `themes` directory, such that is structured like `themes//...`. + ## Contributing We welcome contributions of all kinds, from **code** and **documentation** to **bug reports** and **feedback**! diff --git a/k8s/k8s.yml b/k8s/k8s.yml index 245911d..f6da13a 100644 --- a/k8s/k8s.yml +++ b/k8s/k8s.yml @@ -5,7 +5,7 @@ metadata: labels: app.kubernetes.io/part-of: ctfpilot app.kubernetes.io/name: ctfd - app.kubernetes.io/version: 1.0.0 + app.kubernetes.io/version: 1.0.1-r.2 app.kubernetes.io/component: scoreboard ctfpilot.com/component: ctfd spec: @@ -18,23 +18,28 @@ spec: type: RollingUpdate selector: matchLabels: - name: ctfd + app.kubernetes.io/name: ctfd + ctfpilot.com/component: ctfd template: metadata: labels: - name: ctfd + app.kubernetes.io/part-of: ctfpilot + app.kubernetes.io/name: ctfd + app.kubernetes.io/version: 1.0.1-r.2 + app.kubernetes.io/component: scoreboard + ctfpilot.com/component: ctfd spec: containers: - - image: ghcr.io/ctfpilot/ctfd:1.0.0 + - image: ghcr.io/ctfpilot/ctfd:1.0.1-r.2 imagePullPolicy: Always name: ctfd resources: requests: - cpu: "500m" - memory: "2Gi" + cpu: "100m" + memory: "1Gi" limits: cpu: "2000m" - memory: "8Gi" + memory: "4Gi" livenessProbe: httpGet: path: /healthcheck @@ -206,7 +211,7 @@ metadata: labels: app.kubernetes.io/part-of: ctfpilot app.kubernetes.io/name: ctfd - app.kubernetes.io/version: 1.0.0 + app.kubernetes.io/version: 1.0.1-r.2 app.kubernetes.io/component: scoreboard ctfpilot.com/component: ctfd spec: diff --git a/plugins/ctfd-discord-webhook-plugin b/plugins/ctfd-discord-webhook-plugin new file mode 160000 index 0000000..b07630c --- /dev/null +++ b/plugins/ctfd-discord-webhook-plugin @@ -0,0 +1 @@ +Subproject commit b07630cdb7829a326ce70342ddf359b4130115d0 diff --git a/plugins/dynamic_challenges_mod b/plugins/dynamic_challenges_mod new file mode 160000 index 0000000..6c7ded3 --- /dev/null +++ b/plugins/dynamic_challenges_mod @@ -0,0 +1 @@ +Subproject commit 6c7ded3bd8078454f509d6958c98c8ab6f0ebcc0 diff --git a/plugins/kubectf-plugin b/plugins/kubectf-plugin new file mode 160000 index 0000000..cc1cbc8 --- /dev/null +++ b/plugins/kubectf-plugin @@ -0,0 +1 @@ +Subproject commit cc1cbc89eed17407d62d0a4186a51c94ccc5b5cc diff --git a/template/k8s.yml b/template/k8s.yml index fb8a92b..8a1448d 100644 --- a/template/k8s.yml +++ b/template/k8s.yml @@ -18,11 +18,16 @@ spec: type: RollingUpdate selector: matchLabels: - name: ctfd + app.kubernetes.io/name: ctfd + ctfpilot.com/component: ctfd template: metadata: labels: - name: ctfd + app.kubernetes.io/part-of: ctfpilot + app.kubernetes.io/name: ctfd + app.kubernetes.io/version: { .Version } + app.kubernetes.io/component: scoreboard + ctfpilot.com/component: ctfd spec: containers: - image: ghcr.io/ctfpilot/ctfd:{ .Version } @@ -30,11 +35,11 @@ spec: name: ctfd resources: requests: - cpu: "500m" - memory: "2Gi" + cpu: "100m" + memory: "1Gi" limits: cpu: "2000m" - memory: "8Gi" + memory: "4Gi" livenessProbe: httpGet: path: /healthcheck