This API allows to interface the database and handles business functions
Different ways can be used to spin up a backend Hello API.
First of, you need to create a postgreSQL DB if it's not already done.
⚠️ If your database is already created and running, you can skip this step and directly go to Run the image.
Access this repository to get started!
There is two ways you can install the API:
- Using a docker image: Docker Installation
- This method doesn't allows you to modify easily the existing code and is more suited for a local server when there is only front-end development to be done.
- Using the classic approach with Visual Studio: Local Installation
Start by pulling the image from docker hub
docker pull ghcr.io/applets/backend-hello:<VERSION>
multiple versions are available, you can check them here
The default one is latest
but for cutting edge updates you can use main
branch name.
You'll need to setup the environment variables in the .env
file
Simply copy and paste the .env.template
file, rename it to .env
and fill it with the correct value.
Then, run the image on your local machine
docker run --env-file .env --restart always -d -p 8080:8080 -v <PATH_TO_VOLUME_FOLDER>:/app/volume:rw --name ps-api ghcr.io/applets/backend-hello:<VERSION>
You can navigate to http://localhost:8080/swagger
to check if the API is running correctly!
You will need a couple of things to get started developing and maintaining Hello-Backend.
- Docker (suppose to be already installed at this point)
- Git
- Visual Studio 2022 or above version.
- Make sure to check the ASP.NET and web development component
- .NET8 (which is supposed to come package with VS2022, but in case it's not.)
- Open Bash, navigate to somewhere you like:
cd path/to/repo
- Clone the repo using an ssh key or without:
# With an SSH Key
git clone git@github.com:ApplETS/Backend-Hello.git
# Without an ssh key
git clone https://github.com/ApplETS/Backend-Hello.git
- Open the .sln in Visual Studio 2022
- You'll now need to create your
.env
file from the.env.template
. You can ask help to fill the empty values from a project maintainer.
To run the app make sure to check Docker to run it using docker:
You can navigate to http://localhost:8080 where you're app is running.