Ampersand and Docker
Ampersand uses the following container images:
- haskell:9.6.4(https://hub.docker.com/r/haskell:9.6.4)
This image features the Haskell compiler, which is used to compile the Ampersand compiler. It is used by ~/git/Ampersand/Dockerfile. - debian:bullseye
This image is the base image for the devcontainer in which you work on the Ampersand compiler. It is used as base image by the Dockerfile of the devcontainer. - ampersandtarski/ampersand-devcontainer
This image features the devcontainer in which you work on the Ampersand compiler. Among other things, it contains the Haskell build stack to compile Ampersand with. It is used by contributors to the Ampersand project who use VS-code for developing the Ampersand compiler. Its purpose is to provide all contributors to the Ampersand compiler with the same development environment, to facilitate collaboration. - ampersandtarski/ampersand
This image features the Ampersand compiler, which compiles Ampersand scripts into prototypes and documentation. It is used by the RAP system to compile and run specifications of information systems. - ampersandtarski/ampersand-rap
This image features the RAP development system, which compiles Ampersand scripts into prototypes and documentation. RAP is a tool that lets you analyze Ampersand models, generate functional specifications, and make prototypes of information systems. It is the primary tool for students at the Open University of the Netherlands in the course Rule Based Design. This image is used by the docker-compose.yml file that configures the RAP system to deploy RAP. - mariadb:10.4
This image features the MariaDB database management system. It is used by the docker-compose.yml file that configures the RAP system. Its purpose is to provide database storage for the population of an Ampersand prototype. - phpmyadmin/phpmyadmin
This image features the PHPMyAdmin database client. It is used by the docker-compose.yml file that configures the RAP system. Its purpose is to view the MariaDB database for inspecting the population of an Ampersand prototype. It may be used by contributors to the Ampersand project and should not be used by users of Ampersand. - ampersandtarski/prototype-framework
This image features the prototype framework, which is the base image for prototypes generated by Ampersand. This image contains an Apache webserver that hosts the generated system. It is used in each Dockerfile of a generated system. Its purpose is to host information systems, or parts thereof, that are generated by Ampersand.
Different aspects of the Ampersand user's environment can be containerized 1. Ampersand compiler 1. Modelling environment for Ampersand user (incl. VSCode extensions) 1. Prototype environment, including:
- Apache webserver with PHP
- Ampersand compiler
- PHP-composer
- NPM (Node Package Manager)
- Gulp
- Multi-stage prototype build, only:
- Apache webserver with PHP
- Generated code
- Prototype database
- MariaDB with default user/password
A docker-compose file is available to deploy prototype, database and supporting tools (like phpMyAdmin)
Deploy your local environment to run Ampersand prototypes
Detailed technical instructions are at https://github.com/AmpersandTarski/RAP under the directory listing. This page provides more general and summarized information as context.
The project-template repository contains a docker-compose and Dockerfile to generate, build and run a prototype application.
Run: docker-compose up -d
to deploy the following services:
- Apache webserver
- Serves your prototypes
- Available in the browser at
http://localhost:80
- phpMyAdmin dashboard
- Available in the browser at
http://localhost:8080
- Available in the browser at
- MariaDB database
- Not directly exposed on host
Install instructions for Windows
- Install Docker from https://docs.docker.com/install/ and start the desktop app
- Go to https://github.com/AmpersandTarski/RAP
- Click on the green “Code” button and pull down to “Download ZIP”
- Download the zip and copy the directory on your laptop
- With a command line interface:
- docker-compose up –d
- you may need to enter “docker network create proxy” and repeat “docker-compose up –d”. The second time is a lot faster
- Go to the Docker desktop app
- Find rap-master or the name you gave this docker app
- Click the play button (the triangle)
- Go to “localhost” on your browser and RAP should be running there as it does on the course server
- If that doesn’t work then to back to docker and stop and restart rap4 but enter “2020” as the port and go on the browser to “localhost:2020”
RAP's GitHub site has more technical install instructions at https://github.com/AmpersandTarski/RAP/blob/master/README.md