Skip to content
This repository has been archived by the owner on Mar 17, 2023. It is now read-only.

Commit

Permalink
Merge pull request #15 from OriolBonjoch/master
Browse files Browse the repository at this point in the history
Removed notes, fixed footer gap and hide Twitter if not configured
  • Loading branch information
olgamarti authored Nov 25, 2019
2 parents be4959e + 87082a2 commit dec38c3
Show file tree
Hide file tree
Showing 37 changed files with 1,464 additions and 6,437 deletions.
19 changes: 0 additions & 19 deletions Deploy/helm/dotnet-player/templates/NOTES.txt

This file was deleted.

15 changes: 1 addition & 14 deletions Deploy/helm/game-api/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,19 +1,6 @@
1. Get the application URL by running these commands:
{{- if .Values.ingress.enabled }}
{{- range .Values.ingress.hosts }}
http{{ if $.Values.ingress.tlsEnabled }}s{{ end }}://{{ . }}{{ $.Values.ingress.path }}
http{{ if $.Values.ingress.tlsEnabled }}s{{ end }}://{{ . }}{{ $.Values.inf.ingress.game.path }}
{{- end }}
{{- else if contains "NodePort" .Values.service.type }}
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "rpsls-game.fullname" . }})
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
echo http://$NODE_IP:$NODE_PORT
{{- else if contains "LoadBalancer" .Values.service.type }}
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
You can watch the status of by running 'kubectl get svc -w {{ template "rpsls-game.fullname" . }}'
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "rpsls-game.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo http://$SERVICE_IP:{{ .Values.service.port }}
{{- else if contains "ClusterIP" .Values.service.type }}
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ template "rpsls-game.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
echo "Visit http://127.0.0.1:8080 to use your application"
kubectl port-forward $POD_NAME 8080:80
{{- end }}
19 changes: 0 additions & 19 deletions Deploy/helm/java-player/templates/NOTES.txt

This file was deleted.

3 changes: 2 additions & 1 deletion Deploy/helm/java-player/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ metadata:
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
APPLICATION_INSIGHTS_IKEY: {{ .Values.inf.appinsights.id }}
APPLICATION_INSIGHTS_IKEY: {{ .Values.inf.appinsights.id }}
APPLICATION_INSIGHTS_ENABLED: {{ if .Values.inf.appinsights.id }}'true'{{ else }}'false'{{ end }}
PREDICTOR_URL: {{ .Values.inf.apiurls.predictor }}
19 changes: 0 additions & 19 deletions Deploy/helm/node-player/templates/NOTES.txt

This file was deleted.

19 changes: 0 additions & 19 deletions Deploy/helm/php-player/templates/NOTES.txt

This file was deleted.

19 changes: 0 additions & 19 deletions Deploy/helm/python-player/templates/NOTES.txt

This file was deleted.

18 changes: 4 additions & 14 deletions Deploy/helm/web/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,19 +1,9 @@
1. Get the application URL by running these commands:
{{- if .Values.ingress.enabled }}
{{- range .Values.ingress.hosts }}
http{{ if $.Values.ingress.tlsEnabled }}s{{ end }}://{{ . }}{{ $.Values.ingress.path }}
http{{ if $.Values.ingress.tlsEnabled }}s{{ end }}://{{ . }}{{ $.Values.inf.ingress.web.path }}
{{- if $.Values.uploaderEnabled }}
http{{ if $.Values.ingress.tlsEnabled }}s{{ end }}://{{ . }}{{ $.Values.inf.ingress.web.uploaderPath }}
{{- end }}
{{- end }}
{{- else if contains "NodePort" .Values.service.type }}
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "rpsls-web.fullname" . }})
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
echo http://$NODE_IP:$NODE_PORT
{{- else if contains "LoadBalancer" .Values.service.type }}
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
You can watch the status of by running 'kubectl get svc -w {{ template "rpsls-web.fullname" . }}'
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "rpsls-web.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo http://$SERVICE_IP:{{ .Values.service.port }}
{{- else if contains "ClusterIP" .Values.service.type }}
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ template "rpsls-web.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
echo "Visit http://127.0.0.1:8080 to use your application"
kubectl port-forward $POD_NAME 8080:80
{{- end }}
10 changes: 0 additions & 10 deletions Deploy/powershell/gvalues.template
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,6 @@ inf:
googleanalytics:
id: {{googleanalyticsid}}
ingress:
dotnet:
path: /dotnet-player
node:
path: /node-player
python:
path: /python-player
php:
path: /php-player
java:
path: /java-player
game:
path: /game-manager
web:
Expand Down
10 changes: 0 additions & 10 deletions Deploy/powershell/gvalues.template.gh
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,6 @@ inf:
googleanalytics:
id: {{googleanalyticsid}}
ingress:
dotnet:
path: /dotnet-player
node:
path: /node-player
python:
path: /python-player
php:
path: /php-player
java:
path: /java-player
game:
path: /game-manager
web:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.ApplicationInsights.AspNetCore" Version="2.8.2" />
<PackageReference Include="Microsoft.VisualStudio.Azure.Containers.Tools.Targets" Version="1.4.10" />
</ItemGroup>

Expand Down
4 changes: 1 addition & 3 deletions Source/Services/RPSLS.DotNetPlayer.Api/Startup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,6 @@
using RPSLS.DotNetPlayer.Api.Settings;
using RPSLS.DotNetPlayer.API.Services;
using RPSLS.DotNetPlayer.API.Settings;
using RPSLS.DotNetPlayer.API.Strategies;
using System;
using System.Net.Http;

namespace RPSLS.DotNetPlayer.API
{
Expand All @@ -27,6 +24,7 @@ public void ConfigureServices(IServiceCollection services)
{
services.Configure<StrategySettings>(Configuration);
services.Configure<PredictorSettings>(Configuration);
services.AddApplicationInsightsTelemetry();
services.AddControllers();
services.AddHealthChecks();
services.AddHttpClient("Predictor");
Expand Down
7 changes: 6 additions & 1 deletion Source/Services/RPSLS.JavaPlayer.Api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,12 @@
<artifactId>json-simple</artifactId>
<version>1.1.1</version>
</dependency>
</dependencies>
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>applicationinsights-spring-boot-starter</artifactId>
<version>2.5.1</version>
</dependency>
</dependencies>

<build>
<plugins>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
rpsls.player.pick.strategy=${PICK_STRATEGY:random}
rpsls.predictor.pick.url=${PREDICTOR_URL:}
rpsls.predictor.pick.url=${PREDICTOR_URL:}
azure.application-insights.instrumentation-key=${APPLICATION_INSIGHTS_IKEY:00000000-0000-0000-0000-000000000000}
azure.application-insights.enabled=${APPLICATION_INSIGHTS_ENABLED:false}
4 changes: 0 additions & 4 deletions Source/Services/RPSLS.ModelUploader.Web/Startup.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
Expand Down
10 changes: 9 additions & 1 deletion Source/Services/RPSLS.NodePlayer.Api/index.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
const express = require('express');
const cors = require('cors');
require('dotenv').config();
const appInsights = require("applicationinsights");

const routes = require('./api/routes/index.route');

require('dotenv').config();

// Start application insights
const applicationInsightsIK = process.env.APPLICATION_INSIGHTS_IKEY;
if (applicationInsightsIK) {
appInsights.setup(applicationInsightsIK).start();
}

const app = express();

// Application-Level Middleware
Expand Down
Loading

0 comments on commit dec38c3

Please sign in to comment.