add drone config

This commit is contained in:
Sergo 2023-07-29 22:12:35 +03:00
parent e08522a2a6
commit 2e22c75ab7
3 changed files with 48 additions and 36 deletions

35
.drone.yml Normal file
View File

@ -0,0 +1,35 @@
kind: pipeline
type: kubernetes
name: build
steps:
- name: docker
image: harbor.k-space.ee/k-space/drone-kaniko
settings:
repo: ${DRONE_REPO}
tags: ${DRONE_BRANCH}
registry: harbor.codemowers.eu
username:
from_secret: docker_username
password:
from_secret: docker_password
- name: test
image: harbor.codemowers.eu/msergo/walias:${DRONE_COMMIT_SHA}
settings:
registry: harbor.codemowers.eu
username:
from_secret: docker_username
password:
from_secret: docker_password
commands:
- npm test
# services:
# - name: mysql
# image: mysql:8
# environment:
# MYSQL_ROOT_PASSWORD: dev
# MYSQL_DATABASE: sky
image_pull_secrets:
- dockerconfigjson

View File

@ -8,6 +8,7 @@ module.exports = {
},
wildDuck: {
url: process.env.WILDDUCK_URL,
token: process.env.WILDDUCK_TOKEN
token: process.env.WILDDUCK_TOKEN,
domain: process.env.WILDDUCK_DOMAIN
}
};

View File

@ -1,42 +1,18 @@
# walias
> Aliases for Wild Duck
> Manage email aliases for Wild Duck mail server
## About
This project uses [Feathers](http://feathersjs.com). An open source framework for building APIs and real-time applications.
This project was build for [K-Space Hackathon2023](https://wiki.k-space.ee/en/hackathon/2023)
## Getting Started
## Features
* auth with oidc
* headless only, no DB
* develop/debug with skaffold on k8s cluster
1. Make sure you have [NodeJS](https://nodejs.org/) and [npm](https://www.npmjs.com/) installed.
2. Install your dependencies
```
cd path/to/walias
npm install
```
3. Start your app
```
npm run compile # Compile TypeScript source
npm run migrate # Run migrations to set up the database
npm start
```
## Testing
Run `npm test` and all your tests in the `test/` directory will be run.
## Scaffolding
This app comes with a powerful command line interface for Feathers. Here are a few things it can do:
```
$ npx feathers help # Show all commands
$ npx feathers generate service # Generate a new Service
```
## Help
For more information on all the things you can do with Feathers visit [docs.feathersjs.com](http://docs.feathersjs.com).
## TODO
* remove TS-related hacks
* add tests
* make nicer UI
* implement persistent sessions for multi-docker deployment (redis, db, etc)