work in progress
Re-writing Kitspace to use Gitea as a Git and authentication service.
Allow people to:
- Add projects without knowing Git/Github
- Still import/sync external Git repositories
- Edit/make improvements and propose these changes to project creators
- Get all the source code
git clone https://github.com/kitspace/kitspace-v2
cd kitspace-v2
git submodule update --init
- Install Docker and docker-compose (on Ubuntu:
snap install docker
andapt install docker-compose
) - Add the required lines to
/etc/hosts
(If you are not using Linux this probably won't work, please open an issue and we'll figure out how to support non-Linux development).
cat ./config/hosts | sudo tee -a /etc/hosts
- Copy the example .env
cp .env.example .env
- Build and run the docker containers
docker-compose up
- Go to gitea.kitspace.test:3000/user/sign_up and create a new user. This will be the admin user.
The frontend is a NextJS server in the frontend directory. Making edits on the code should auto compile and reload at kitspace.test:3000.
Changing dependencies requires you to restart the development container:
cd frontend
yarn add <new dependency>
cd ..
docker-compose restart frontend
This is built from a git submodule of our fork of Gitea.
When it first builds the docker container it builds the whole Gitea project (make clean-all build
). When you restart the container it recompiles only the backend and doesn't recompile unchanged files (make backend
).
This is a NodeJS and Express server that processes all the assets. As with the frontend, changing dependencies requires you to restart the development container.
This repo auto deploys the master
branch (whether e2e tests pass or not) to our staging server.
We also auto deploy some development branches:
- abdo-dev.staging.kitspace.dev (from abdo-dev, @AbdulrhmnGhanem's branch)
- kaspar-dev.staging.kitspace.dev (from kaspar-dev, @kasbah's branch)
We configure our staging servers using Ansible. Our playbooks and roles are in the ansible directory.
-
Make sure the frontend is being served at http://kitspace.test:3000; by following the
Set Up
steps. -
navigate to
frontend
:cd frontend/
. -
Source the
.env
file withset -a && source ../.env && set +a
-
Start the testing client with the
npx cypress open
command. -
The Cypress GUI should pop up.
-
To run all tests, press
Run all specs
.