Skip to content

Commit

Permalink
Update build-container.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Layoric authored Dec 4, 2024
1 parent a26880a commit 81f6b2d
Showing 1 changed file with 1 addition and 20 deletions.
21 changes: 1 addition & 20 deletions .github/workflows/build-container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,38 +42,19 @@ jobs:
echo "HAS_DEPLOY_ACTION=false" >> $GITHUB_ENV
fi
# This step is for the deployment of the templates only, safe to delete
- name: Modify csproj for template deploy
if: env.HAS_DEPLOY_ACTION == 'true'
run: |
sed -i 's#<ContainerLabel Include="service" Value="my-app" />#<ContainerLabel Include="service" Value="${{ env.repository_name_lower }}" />#g' MyApp/MyApp.csproj
- name: Check for Client directory and package.json
id: check_client
run: |
if [ -d "MyApp.Client" ] && [ -f "MyApp.Client/package.json" ]; then
echo "client_exists=true" >> $GITHUB_OUTPUT
else
echo "client_exists=false" >> $GITHUB_OUTPUT
fi
- name: Setup Node.js
if: steps.check_client.outputs.client_exists == 'true'
uses: actions/setup-node@v3
with:
node-version: 22

- name: Install npm dependencies
if: steps.check_client.outputs.client_exists == 'true'
working-directory: ./MyApp.Client
run: npm install

- name: Install x tool
run: dotnet tool install -g x

- name: Apply Production AppSettings
if: env.HAS_APPSETTINGS_PATCH == 'true'
working-directory: ./MyApp
working-directory: ./AiServer
run: |
cat <<EOF >> appsettings.json.patch
${{ secrets.APPSETTINGS_PATCH }}
Expand Down

0 comments on commit 81f6b2d

Please sign in to comment.