Skip to content

Commit

Permalink
dsdf
Browse files Browse the repository at this point in the history
  • Loading branch information
csnhawkins committed Feb 8, 2025
1 parent 7f3114a commit dcea6a0
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/GitHub-Code-Validation-Checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,20 @@ jobs:
- name: Checkout Code
uses: actions/checkout@v4

- name: Start SQL Server with Access to Backups & Scripts and Enable TCP/IP
- name: Start SQL Server with Access to Backups & Scripts
run: |
docker run -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=${{ env.SA_PASSWORD }}" \
-p ${{ env.DB_PORT }}:1433 -d \
-v ${{ github.workspace }}/backups:/var/opt/mssql/backups \
-v ${{ github.workspace }}/Scripts:/var/opt/mssql/scripts \
${{ env.DB_IMAGE }} \
/bin/bash -c " \
# Enable TCP/IP in SQL Server configuration \
/opt/mssql-tools18/bin/sqlcmd -S localhost -U sa -P '${{ env.SA_PASSWORD }}' -Q \
\"EXEC sp_configure 'remote access', 1; RECONFIGURE;\" && \
# Restart SQL Server for the changes to take effect \
/opt/mssql/bin/sqlservr --accept-eula"
${{ env.DB_IMAGE }}
- name: Enabled TCP/IP
run: |
CONTAINER_ID=$(docker ps -q --filter ancestor=${{ env.DB_IMAGE }})
docker exec -i $CONTAINER_ID /bin/bash -c "
/opt/mssql-tools18/bin/sqlcmd -S 'localhost,${{ env.DB_PORT }}' -U sa -P '${{ env.SA_PASSWORD }}' -Q \
\"EXEC sp_configure 'remote access', 1; RECONFIGURE;\"
- name: Wait for SQL Server to be ready
run: |
Expand Down

0 comments on commit dcea6a0

Please sign in to comment.