Pageous

Building Your Project

So far our Tutorial Project has a couple pages and a form but we’ve only been able to preview it with our example data. Now we will build the project and run it against the live JSONPlaceholder service.

Builds require a paid subscription to Pageous but if you’re a first time user you can get a 14 day free trial. Clicking “Builds” will redirect you to the Billing page if you are not subscribed. Subscribe to the Unlimited Plan by following the instructions in the billing flow.

Once subscribed you can click the arrow in the top right to get back to the project editor. Clicking “Builds” in the left menu will now bring you to the Builds page.

Configuring a Container Repository

A container repository needs to be configured to create builds. This is where the Docker images of your builds will be stored. A quick way to check your credentials for this form is to use the docker login command on the CLI:

docker login <Registry address> -u <Username>
Password: <Access token>

If this command returns “Login Succeeded” then those credentials will work here. Just remember that for security you need to generate a personal access token and not use your password directly. The token you generate will need read and write access to the container registry.

For more information on access tokens and container registries of popular services see:

Service Container Registry Doc Personal Access Token Doc
Github Working with the container registry Managing your personal access tokens
Gitlab GitLab container registry Personal access tokens
Docker Hub   Create and manage access tokens

If you’re using some other service ypu can usually find this information by googling “<name of service> container registry” and “<name of service> access tokens”.

Knowing this, let’s go through this form:

Username: The username on the container registry service you are using.

Repository name: The fully qualified repository name. For example on github this would be ghcr.io/<username or organization>/<repo>

Access token: Generated using the instructions above.

Registry address: Usually the hostname where the registry is located. It’s often something like: registry.example.com or in the case of github: ghcr.io

Click “Create Container Repository” to finish the configuration.

Creating a Build

Navigate back to the “Builds” page and click “New Build”. On this screen you are given the option to change the container repository and the tag. The defaults here are fine so go ahead and click “Create Build”. The build should only take a few seconds. Once it’s done the status should change from started to completed when you refresh the page.

Now you can pull the image and run the container locally:

docker login <Registry address> -u <username>
docker pull <Repository name>
docker run -p 8080:80 -e JSONPLACEHOLDER_HOSTNAME=jsonplaceholder.typicode.com -it <Repository name>

There you go! You’re now running your Pageous project build locally. You can navigate to http://localhost:8080/users/2 to see a user that isn’t in our example data. Unfortunately our form doesn’t work correctly because JSONPlaceholder doesn’t actually create any new data. Now you’re ready to start making your own project.