Power BI Public (Gateway)

Build Status

An app that will publicly display Embedded Power BI reports on GovCloud using a service principle. The following links can help configure Azure and Power BI:

Local Development

Steps to run this application on your local machine for development purposes.

Developer Prerequisites

Running Locally

  • Backend: env SPRING_PROFILES_ACTIVE=development ./gradlew bootRun; http://localhost:8080
    • or for staging environment: env SPRING_PROFILES_ACTIVE=staging ./gradlew bootRun
  • Frontend: cd client && npm run serve; http://localhost:8081

Build Scripts

  • Application: ./build.sh
  • Container: ./build-push-docker-image.sh

Required Environment Variables

  • POWERBI_TENANT_ID: Azure Tenant ID
  • POWERBI_CLIENT_ID: Application ID from the AD App Registration
  • POWERBI_CLIENT_SECRET: Client secret from the AD App Registration
  • FLYWAY_URL: The jdbc connection to the AZURE SQL Database. This string must be in quotes if using MacOS.
  • FLYWAY_USER: Username to the AZURE SQL Database
  • FLYWAY_PASSWORD: Password to the AZURE SQL Database

If running in staging environment, add these additional variables:

  • AZURE_OAUTH_TENANT_ID
  • AZURE_OAUTH_CLIENT_SECRET
  • BUILD_ID=100 (or some placeholder number)
  • GATEWAY_API_TOKEN=faketoken (or some placeholder string)

For details related to the deployment of containerized applications in Azure, reference this repo with deployment scenarios

Database Notes

  • SQL Scripts for updating the Database can be found here: /src/main/resources/db/migration
  • To print details and status information about all the migrations: gradle flywayInfo (Flyway docs)