ci-demo-2/infrastructure
Richard Attermeyer 5c5f658c8b
ci/woodpecker/push/lint_general Pipeline was successful Details
Merge remote-tracking branch 'origin/main' into renovate/pin-dependencies
2024-01-29 13:06:50 +00:00
..
postgresql/initdb.d WIP 2023-12-16 22:22:19 +00:00
sonarqube chore(deps): pin dependencies 2024-01-28 21:41:56 +00:00
traefik WIP: working with correct letsencrypt 2023-12-16 22:22:19 +00:00
verdaccio WIP 2023-12-16 22:22:19 +00:00
README.adoc WIP 2023-12-16 22:22:19 +00:00
compose.yaml Merge remote-tracking branch 'origin/main' into renovate/pin-dependencies 2024-01-29 13:06:50 +00:00
docker-compose.yml.bak WIP 2023-12-16 22:22:19 +00:00
update-ip-addr.sh chore: readme.adoc 2023-11-25 18:15:39 +01:00

README.adoc

= Forgejo

You need to find out the official IP address of your computer.
This can be done using the following command: `./update-ip-addr.sh`
It updates also the .env file and in this file (so you can easily copy and paste the links)

Lets say it is `192.168.1.151` then the URLs for accessing the services are:

|===
|Service | URL | User / Pwd

| Traefik Dashboard | http://traefik.demorattermeyer.de[] |
| git | https://git.demo.rattermeyer.de[] |
| woodpecker | https://ci.demo.rattermeyer.de[] |
| mvn ui | https://mvn-ui.demo.rattermeyer.de[] |
| mvn (repo) | http://mvn.rattermeyer.de[] |
| Mail | https://mail.demo.rattermeyer.de[] |
| Docker Registry | https://container.demo.rattermeyer.de[] |
| Docker Registry UI | https://container-ui.demo.rattermeyer.de[] |
| NPM Registry / proxy | https://npm.demo.rattermeyer.de[] |
|===

First start forgejo using:

`docker compose up -d traefik forgejo`

And then register an (admin) user in forgejo.

E.g., fjadmin / admin123 / fjadmin@rattermeyer.de

Setup > Applications > oauth2 apps

woodpecker / https://ci.demo.rattermeyer.de/authorize

note client-id and client-secret and enter this in .env for.

Now you can start everything using `docker compose up -d`.

== Changing IP

If the IP address of your computer changes, you have to update some configuration.

1. `./update-ip-addr.sh`
2. `docker exec -it -u root forgejo /bin/ash` and then `vi /data/gitea/conf/app.ini`` and change the IP address.
3. `docker compose down`
4. `docker volume rm forgejo_woodpecker``
5. `docker compose up -d`

== Check access to woodpecker

Access https://ci.demo.rattermeyer.de and try to login.


== Create and push a repository

In forgejo, you should create a new repository, called ci-demo-2.

You need to disable ssl verification for this remote in your local git directory:

     git config http.sslVerify false

Then add the repository

git remote add origin https://git.demo.rattermeyer.de:8543/fjadmin/ci-demo-2.git

and push it

git push -u --all origin

You need also at least one tag.

git push --tags origin

== Adding Repo to woodpecker

In woodpecker, you need to add the repository.
It should be listed in the repositories list if you try to add it.

You need to "activate" the repository in woodpecker using the button.