Skip to content

Commit

Permalink
Added infrastructure and bicep
Browse files Browse the repository at this point in the history
jonerlend committed Oct 11, 2023
1 parent 744dcdf commit a947684
Showing 22 changed files with 13 additions and 9 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/dev_atil-feecalculator.yml
Original file line number Diff line number Diff line change
@@ -16,13 +16,15 @@ jobs:
- name: Install dependencies
run: dotnet restore .
- name: Build
run: dotnet publish --configuration Release --no-restore -o publish
run: dotnet publish ./src/ATIL.FeeCalculator.csproj --configuration Release --no-restore -o publish
- name: checkout octopus
uses: OctopusDeploy/[email protected]
- name: pack & push to octo
run: |
BRANCHNAME=${{github.ref_name}}
MY_VAR="1.0.${{github.run_number}}-beta"
octo pack --basePath=infrastructure --id atil_feecalculator-infrastructure --version $MY_VAR --outFolder ./infra --format zip
octo push --package "./infra/atil_feecalculator-infrastructure.${MY_VAR}.zip" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}"
octo pack --basePath=publish --id atil_feecalculator --version $MY_VAR --outFolder ./out --format zip
octo push --package "./out/atil_feecalculator.${MY_VAR}.zip" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}"
octo create-release --project="ATIL - Fee Calculator API" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}" --channel=Dev
4 changes: 3 additions & 1 deletion .github/workflows/main_atil-feecalculator.yml
Original file line number Diff line number Diff line change
@@ -16,12 +16,14 @@ jobs:
- name: Install dependencies
run: dotnet restore .
- name: Build
run: dotnet publish --configuration Release --no-restore -o publish
run: dotnet publish ./src/ATIL.FeeCalculator.csproj--configuration Release --no-restore -o publish
- name: checkout octopus
uses: OctopusDeploy/[email protected]
- name: pack & push to octo
run: |
MY_VAR="1.0.${{github.run_number}}"
octo pack --basePath=infrastructure --id atil_feecalculator-infrastructure --version $MY_VAR --outFolder ./infra --format zip
octo push --package "./infra/atil_feecalculator-infrastructure.${MY_VAR}.zip" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}"
octo pack --basePath=publish --id atil_feecalculator --version $MY_VAR --outFolder ./out --format zip
octo push --package "./out/atil_feecalculator.${MY_VAR}.zip" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}"
octo create-release --project="ATIL - Fee Calculator API" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}" --channel=Prod
11 changes: 6 additions & 5 deletions .github/workflows/test_atil-feecalculator.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
on:
on:
push:
branches:
- "release/rc-*"
@@ -11,19 +11,20 @@ jobs:
- name: Set up .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '6.0.x'
dotnet-version: "6.0.x"
include-prerelease: true
- name: Install dependencies
run: dotnet restore .
- name: Build
run: dotnet publish --configuration Release --no-restore -o publish
run: dotnet publish ./src/ATIL.FeeCalculator.csproj--configuration Release --no-restore -o publish
- name: checkout octopus
uses: OctopusDeploy/[email protected]
- name: pack & push to octo
- name: pack & push to octo
run: |
BRANCHNAME=${{github.ref_name}}
MY_VAR="1.0.${{github.run_number}}-${BRANCHNAME##*/}"
octo pack --basePath=infrastructure --id atil_feecalculator-infrastructure --version $MY_VAR --outFolder ./infra --format zip
octo push --package "./infra/atil_feecalculator-infrastructure.${MY_VAR}.zip" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}"
octo pack --basePath=publish --id atil_feecalculator --version $MY_VAR --outFolder ./out --format zip
octo push --package "./out/atil_feecalculator.${MY_VAR}.zip" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}"
octo create-release --project="ATIL - Fee Calculator API" --server="${{ secrets.OCTOPUS_SERVER }}" --apiKey="${{ secrets.OCTOPUS_APIKEY }}" --channel=Test
2 changes: 1 addition & 1 deletion ATIL.FeeCalculator.sln
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.31424.327
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ATIL.FeeCalculator", "ATIL.FeeCalculator.csproj", "{AF0561E3-EEDE-4F28-90D3-1BD172D1F8D7}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ATIL.FeeCalculator", "src\ATIL.FeeCalculator.csproj", "{AF0561E3-EEDE-4F28-90D3-1BD172D1F8D7}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion Startup.cs → src/Startup.cs
Original file line number Diff line number Diff line change
@@ -54,7 +54,6 @@ public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
app.UseMiddleware(typeof(ExceptionHandlingMiddleware));
app.UseEndpoints(endpoints =>
{
endpoints.MapGet("/ping", () => "pongers");
endpoints.MapControllers();
endpoints.MapHealthChecks("/health");
});

0 comments on commit a947684

Please sign in to comment.