The main repository is located at https://github.com/altinn/altinn-studio and this is part of the Pi Challenge: https://github.com/Altinn/altinn-studio/issues/5912
Altinn Studio is the next generation Altinn application development solution.
Together with Altinn Apps and Altinn Platform (also part of this repo), this is a complete application development and hosting platform.
Altinn Studio is available at https://altinn.studio.
Use the documentation to get started.
If you just want to run apps locally go here
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
Clone the Altinn Studio repo and navigate to the folder.
git clone https://github.com/Altinn/altinn-studio
cd altinn-studio
Follow the instructions found here.
If you only need to develop and debug App-Frontend, you can follow the description in 5) (only) and deploy the app to any test environment. The App-Frontend will be loaded from your local webpack-dev-server.
It's possible to run an app locally in order to test and debug it. It needs a local version of the platform services to work.
NOTE: Currently, it is not possible to run Apps and Altinn Studio (designer) in parallel. To run Apps, make sure that none of the containers for Altinn Studio are running, f.ex. by navigating to the root of the altinn-studio repo, and running the command
docker-compose down
Setting up local platform services for test
development
folder in the altinn-studio repocd src/development
docker-compose up -d --build
appSettings.json
in the LocalTest
folder, f.ex. in Visual Studio Codecd LocalTest
code appSettings.json
"AppRepsitoryBasePath"
to the full path to your app on the disk. Save the file.dotnet run
cd \.\<path to app on disk>
If you need to debug (or run locally) the app front-end:
views/Home/Index.cshtml
and change the line<script src="https://altinncdn.no/toolkits/altinn-app-frontend/2/altinn-app-frontend.js"></script>
to
<script src="http://localhost:8080/altinn-app-frontend.js"></script>
altinn-studio/src/Altinn.Apps/AppFrontend/react
):
npm install # only needed first time, or when dependencies are updated
npm run install-deps # only needed first time, or when dependencies are updated
cd altinn-app-frontend
npm start
dotnet run -p App.csproj
The app and local platform services are now running locally. The app can be accessed on altinn3local.no.
Log in with a test user, using your app name and org name. This will redirect you to the app.
If you need to rebuild other react apps, for instance Dashboard or ServiceDevelopment, this can be done by navigating to their respective folders, example src/react-apps/applications/dashboard
and then run the following build script
npm run build
Some of the react projects also have various other predefined npm tasks, which can be viewed in the package.json
file which is located in the root folder of each react project, example src/react-apps/applications/dashboard/package.json
The platform receipt component can run locally, both in docker and manually.
Manual
src/Altinn.Platform/Altinn.Platform.Receipt
npm install
npm run gulp
(if running for the first time, otherwise this can be skipped)npm run gulp-install-deps
npm run gulp-develop
This will build and run receipt back end, and build and copy the receipt frontend to the wwwroot
folder.
The application should now be available at localhost:5060/receipt/{instanceOwnerId}/{instanceId}
The script wil also listen to changes in the receipt react app, rebuild and copy the new react app to the wwwroot
folder.
Docker
src/Altinn.Platform/Altinn.Platform.Receipt
docker-compose up
localhost:5060/receipt/{instanceOwnerId}/{instanceId}
Integration tests for local studio.
Coding style tests are available for the React front end application, using tslint.
Navigate to the React front end application and run linting.
cd src/react-apps/applications/ux-editor
npm run lint
The current build is deployed in Kubernetes on Azure.
Automated build/deploy process is being developed.
Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.
See also the list of contributors who participated in this project.
This project is licensed under the 3-Clause BSD License - see the LICENSE.md file for details.