Merge remote-tracking branch 'origin/develop' into feature/customBriefingSupplyMissions
This commit is contained in:
@@ -21,6 +21,9 @@
|
|||||||
<main>
|
<main>
|
||||||
<div class="reference-container">
|
<div class="reference-container">
|
||||||
<div class="side-nav">
|
<div class="side-nav">
|
||||||
|
|
||||||
|
<div id="beta-box-div"></div>
|
||||||
|
|
||||||
<h4>Quick Links</h4>
|
<h4>Quick Links</h4>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="/pages/tutorials.html" class="side-nav-h2">Tutorials</a></li>
|
<li><a href="/pages/tutorials.html" class="side-nav-h2">Tutorials</a></li>
|
||||||
@@ -59,6 +62,13 @@
|
|||||||
<footer>
|
<footer>
|
||||||
<p>© 2025 Spearhead Project</p>
|
<p>© 2025 Spearhead Project</p>
|
||||||
</footer>
|
</footer>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
if (true || window.location.hostname.toLowerCase() == 'beta.spearhead.rocks') {
|
||||||
|
betaHtml = '<note-box type="warning" title="Beta Version">You are looking at docs that are released with the beta version.</note-box>';
|
||||||
|
}
|
||||||
|
document.getElementById('beta-box-div').innerHTML = betaHtml || '';
|
||||||
|
</script>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
@@ -168,8 +168,14 @@ class Sidebar extends HTMLElement {
|
|||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
|
var betaHtml = '';
|
||||||
|
if (window.location.hostname.toLowerCase() == 'beta.spearhead.rocks') {
|
||||||
|
betaHtml = '<note-box type="warning" title="Beta Version">You are looking at docs that are released with the beta version.</note-box>';
|
||||||
|
}
|
||||||
|
|
||||||
this.innerHTML = `
|
this.innerHTML = `
|
||||||
<div class="side-nav">
|
<div class="side-nav">
|
||||||
|
${betaHtml}
|
||||||
<h4 class="side-nav-title"></h4>
|
<h4 class="side-nav-title"></h4>
|
||||||
<ul>
|
<ul>
|
||||||
<!-- Navigation items will be populated automatically -->
|
<!-- Navigation items will be populated automatically -->
|
||||||
|
|||||||
@@ -4,13 +4,14 @@ on:
|
|||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
- develop
|
||||||
paths:
|
paths:
|
||||||
- '.docs/**'
|
- '.docs/**'
|
||||||
|
|
||||||
env:
|
env:
|
||||||
DOCKER_REGISTRY: registry.dutchie031.net
|
DOCKER_REGISTRY: registry.dutchie031.net
|
||||||
DOCKER_IMAGE: spearhead-docs
|
DOCKER_IMAGE: spearhead-docs
|
||||||
DOCKER_TAG: latest
|
DOCKER_TAG: ${{ github.ref_name == 'main' && 'latest' || 'beta' }}
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
## Run replacements and cleanups on the docs
|
## Run replacements and cleanups on the docs
|
||||||
@@ -36,7 +37,7 @@ jobs:
|
|||||||
sed -i '/@@API_CODE@@/d' .docs/web/pages/spearheadapi.html
|
sed -i '/@@API_CODE@@/d' .docs/web/pages/spearheadapi.html
|
||||||
rm .docs/web/pages/temp_api_code.html
|
rm .docs/web/pages/temp_api_code.html
|
||||||
|
|
||||||
- name: Highlight API code and update HTML
|
- name: Highlight Config code and update HTML
|
||||||
run: |
|
run: |
|
||||||
pygmentize -f html -l lua -O noclasses,style=monokai ./config.lua > .docs/web/pages/temp_config_code.html
|
pygmentize -f html -l lua -O noclasses,style=monokai ./config.lua > .docs/web/pages/temp_config_code.html
|
||||||
# Insert the highlighted code into the placeholder in spearheadapi.html
|
# Insert the highlighted code into the placeholder in spearheadapi.html
|
||||||
@@ -105,15 +106,30 @@ jobs:
|
|||||||
chmod 600 $HOME/.kube/config
|
chmod 600 $HOME/.kube/config
|
||||||
cat $HOME/.kube/config
|
cat $HOME/.kube/config
|
||||||
|
|
||||||
- name: Run Helm upgrade/install
|
- name: Run Helm upgrade/install spearhead-docs (main)
|
||||||
|
if: github.ref_name == 'main'
|
||||||
run: |
|
run: |
|
||||||
helm upgrade --install spearhead-docs .helm \
|
helm upgrade --install spearhead-docs .helm \
|
||||||
--namespace spearhead-docs \
|
--namespace spearhead-docs \
|
||||||
--create-namespace \
|
--create-namespace \
|
||||||
|
-f .helm/values.yaml \
|
||||||
--set image.repository=${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_IMAGE }} \
|
--set image.repository=${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_IMAGE }} \
|
||||||
--set image.tag=${{ env.DOCKER_TAG }} \
|
--set image.tag=${{ env.DOCKER_TAG }} \
|
||||||
--wait
|
--wait
|
||||||
|
|
||||||
|
- name: Run Helm upgrade/install spearhead-docs (develop)
|
||||||
|
if: github.ref_name == 'develop'
|
||||||
|
run: |
|
||||||
|
helm upgrade --install spearhead-docs-beta .helm \
|
||||||
|
--namespace spearhead-docs \
|
||||||
|
--create-namespace \
|
||||||
|
-f .helm/values.yaml \
|
||||||
|
-f .helm/values.beta.yaml \
|
||||||
|
--set image.repository=${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_IMAGE }} \
|
||||||
|
--set image.tag=${{ env.DOCKER_TAG }} \
|
||||||
|
--wait
|
||||||
|
|
||||||
|
|
||||||
# - name: 'Deploy'
|
# - name: 'Deploy'
|
||||||
# uses: deliverybot/helm@v1
|
# uses: deliverybot/helm@v1
|
||||||
# with:
|
# with:
|
||||||
|
|||||||
@@ -14,3 +14,4 @@ sources:
|
|||||||
maintainers:
|
maintainers:
|
||||||
- name: Spearhead Team
|
- name: Spearhead Team
|
||||||
|
|
||||||
|
|
||||||
@@ -25,7 +25,7 @@ spec:
|
|||||||
type: RuntimeDefault
|
type: RuntimeDefault
|
||||||
containers:
|
containers:
|
||||||
- name: {{ .Values.app }}
|
- name: {{ .Values.app }}
|
||||||
image: {{ .Values.image.repository }}:{{ .Values.image.tag }}
|
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: {{ .Values.ports.containerPort }}
|
- containerPort: {{ .Values.ports.containerPort }}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ spec:
|
|||||||
apiVersion: networking.k8s.io/v1
|
apiVersion: networking.k8s.io/v1
|
||||||
kind: Ingress
|
kind: Ingress
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Values.app }}-ingress
|
name: "{{ .Values.app }}-ingress"
|
||||||
namespace: spearhead-docs
|
namespace: spearhead-docs
|
||||||
annotations:
|
annotations:
|
||||||
kubernetes.io/tls-acme: "true"
|
kubernetes.io/tls-acme: "true"
|
||||||
@@ -22,28 +22,21 @@ metadata:
|
|||||||
spec:
|
spec:
|
||||||
ingressClassName: nginx
|
ingressClassName: nginx
|
||||||
rules:
|
rules:
|
||||||
- host: spearhead.dutchie031.com
|
{{- range .Values.ingress.hosts }}
|
||||||
|
- host: {{ . }}
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
- path: /
|
- path: /
|
||||||
pathType: Prefix
|
pathType: Prefix
|
||||||
backend:
|
backend:
|
||||||
service:
|
service:
|
||||||
name: {{ .Values.app }}
|
name: {{ $.Values.app }}
|
||||||
port:
|
port:
|
||||||
number: {{ .Values.ports.servicePort }}
|
number: {{ $.Values.ports.servicePort }}
|
||||||
- host: spearhead.rocks
|
{{- end }}
|
||||||
http:
|
|
||||||
paths:
|
|
||||||
- path: /
|
|
||||||
pathType: Prefix
|
|
||||||
backend:
|
|
||||||
service:
|
|
||||||
name: {{ .Values.app }}
|
|
||||||
port:
|
|
||||||
number: {{ .Values.ports.servicePort }}
|
|
||||||
tls:
|
tls:
|
||||||
- hosts:
|
- hosts:
|
||||||
- spearhead.dutchie031.com
|
{{- range .Values.ingress.hosts }}
|
||||||
- spearhead.rocks
|
- {{ . }}
|
||||||
secretName: spearhead-docs-tls
|
{{- end }}
|
||||||
|
secretName: "{{ .Values.app }}-docs-tls"
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
|
||||||
|
app: spearhead-docs-beta
|
||||||
|
|
||||||
|
image:
|
||||||
|
tag: "beta"
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
hosts:
|
||||||
|
- beta.spearhead.rocks
|
||||||
@@ -8,3 +8,8 @@ image:
|
|||||||
ports:
|
ports:
|
||||||
servicePort: 80
|
servicePort: 80
|
||||||
containerPort: 80
|
containerPort: 80
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
hosts:
|
||||||
|
- spearhead.dutchie031.com
|
||||||
|
- spearhead.rocks
|
||||||
Reference in New Issue
Block a user