Skip to content

Commit

Permalink
Remove probe port configuration and update related references in Helm…
Browse files Browse the repository at this point in the history
… chart and Docker setup
  • Loading branch information
simlarsen committed Nov 22, 2024
1 parent a4913cc commit fac334d
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 18 deletions.
2 changes: 0 additions & 2 deletions HelmChart/Public/oneuptime/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,6 @@ Usage:
value: {{ $.Values.port.incomingRequestIngest | squote }}
- name: FLUENT_INGEST_PORT
value: {{ $.Values.port.fluentIngest | squote }}
- name: PROBE_PORT
value: {{ $.Values.port.probe | squote }}
- name: TEST_SERVER_PORT
value: {{ $.Values.port.testServer | squote }}
- name: ACCOUNTS_PORT
Expand Down
1 change: 0 additions & 1 deletion HelmChart/Public/oneuptime/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,6 @@ port:
# If you are connecting Status Pages to custom domains, then this will be the port where the status page will be hosted on.
statusPageHttpsPort: 443
haraka: 2525
probe: 3500
otelCollectorGrpc: 4317
otelCollectorHttp: 4318
isolatedVM: 4572
Expand Down
4 changes: 0 additions & 4 deletions Probe/Dockerfile.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,6 @@ RUN npx playwright install --with-deps
COPY ./Probe/package*.json /usr/src/app/
RUN npm install

# Expose ports.
# - 3087: OneUptime-backend
EXPOSE 3087

{{ if eq .Env.ENVIRONMENT "development" }}
#Run the app
CMD [ "npm", "run", "dev" ]
Expand Down
3 changes: 2 additions & 1 deletion Probe/Index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import logger from "Common/Server/Utils/Logger";
import App from "Common/Server/Utils/StartServer";
import Telemetry from "Common/Server/Utils/Telemetry";
import "ejs";
import Port from "Common/Types/Port";

const APP_NAME: string = "probe";

Expand All @@ -22,7 +23,7 @@ const init: PromiseVoidFunction = async (): Promise<void> => {
// init the app
await App.init({
appName: APP_NAME,
port: undefined,
port: new Port(3874), // some random port to start the server. Since this is the probe, it doesn't need to be exposed.
isFrontendApp: false,
statusOptions: {
liveCheck: async () => {},
Expand Down
1 change: 1 addition & 0 deletions Probe/Services/Register.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ export default class Register {

if (result.isSuccess()) {
logger.debug("Probe Registered");
logger.debug(result.data);

const probeId: string = result.data["_id"] as string;

Expand Down
5 changes: 2 additions & 3 deletions config.example.env
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ PROBE_INGEST_PORT=3400
OPEN_TELEMETRY_INGEST_PORT=3403
FLUENT_INGEST_PORT=3401
INCOMING_REQUEST_INGEST_PORT=3402
PROBE_PORT=3500
TEST_SERVER_PORT=3800
ACCOUNTS_PORT=3003
STATUS_PAGE_PORT=3105
Expand Down Expand Up @@ -179,7 +178,7 @@ GLOBAL_PROBE_1_NAME="Probe-1"
GLOBAL_PROBE_1_DESCRIPTION="Global probe to monitor oneuptime resources"
GLOBAL_PROBE_1_MONITORING_WORKERS=5
GLOBAL_PROBE_1_MONITOR_FETCH_LIMIT=10
GLOBAL_PROBE_1_ONEUPTIME_URL=http://probe-ingest:3400
GLOBAL_PROBE_1_ONEUPTIME_URL=http://localhost
GLOBAL_PROBE_1_SYNTHETIC_MONITOR_SCRIPT_TIMEOUT_IN_MS=60000
GLOBAL_PROBE_1_CUSTOM_CODE_MONITOR_SCRIPT_TIMEOUT_IN_MS=60000

Expand All @@ -188,7 +187,7 @@ GLOBAL_PROBE_2_NAME="Probe-2"
GLOBAL_PROBE_2_DESCRIPTION="Global probe to monitor oneuptime resources"
GLOBAL_PROBE_2_MONITORING_WORKERS=5
GLOBAL_PROBE_2_MONITOR_FETCH_LIMIT=10
GLOBAL_PROBE_2_ONEUPTIME_URL=http://probe-ingest:3400
GLOBAL_PROBE_2_ONEUPTIME_URL=http://localhost
GLOBAL_PROBE_2_SYNTHETIC_MONITOR_SCRIPT_TIMEOUT_IN_MS=60000
GLOBAL_PROBE_2_CUSTOM_CODE_MONITOR_SCRIPT_TIMEOUT_IN_MS=60000

Expand Down
9 changes: 2 additions & 7 deletions docker-compose.base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ x-common-variables: &common-variables
OPEN_TELEMETRY_INGEST_PORT: ${OPEN_TELEMETRY_INGEST_PORT}
INCOMING_REQUEST_INGEST_PORT: ${INCOMING_REQUEST_INGEST_PORT}
FLUENT_INGEST_PORT: ${FLUENT_INGEST_PORT}
PROBE_PORT: ${PROBE_PORT}
TEST_SERVER_PORT: ${TEST_SERVER_PORT}
ACCOUNTS_PORT: ${ACCOUNTS_PORT}
STATUS_PAGE_PORT: ${STATUS_PAGE_PORT}
Expand Down Expand Up @@ -351,12 +350,10 @@ services:
max-size: "1000m"

probe-1:
networks:
- oneuptime
restart: always
network_mode: host
environment:
<<: *common-server-variables
PORT: ${PROBE_PORT}
PROBE_NAME: ${GLOBAL_PROBE_1_NAME}
PROBE_DESCRIPTION: ${GLOBAL_PROBE_1_DESCRIPTION}
PROBE_MONITORING_WORKERS: ${GLOBAL_PROBE_1_MONITORING_WORKERS}
Expand All @@ -372,12 +369,10 @@ services:
max-size: "1000m"

probe-2:
networks:
- oneuptime
restart: always
network_mode: host
environment:
<<: *common-server-variables
PORT: ${PROBE_PORT}
PROBE_NAME: ${GLOBAL_PROBE_2_NAME}
PROBE_DESCRIPTION: ${GLOBAL_PROBE_2_DESCRIPTION}
PROBE_MONITORING_WORKERS: ${GLOBAL_PROBE_2_MONITORING_WORKERS}
Expand Down

0 comments on commit fac334d

Please sign in to comment.