Skip to content

Commit

Permalink
GH-458 Reposilite 3.0 (Resolve #458)
Browse files Browse the repository at this point in the history
  • Loading branch information
dzikoysk authored Sep 5, 2021
2 parents c93619e + b0aca9f commit c72189a
Show file tree
Hide file tree
Showing 415 changed files with 18,682 additions and 49,520 deletions.
20 changes: 10 additions & 10 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
version: 2
updates:
- package-ecosystem: maven
directory: "/"
schedule:
interval: daily
time: "04:00"
open-pull-requests-limit: 10
ignore:
- dependency-name: org.webjars:swagger-ui
versions:
- "> 3.25.2"
- package-ecosystem: "gradle"
directory: "/reposilite-backend"
schedule:
interval: "daily"
time: "16:15"
- package-ecosystem: "npm"
directory: "/reposilite-frontend"
schedule:
interval: "daily"
time: "16:15"
12 changes: 8 additions & 4 deletions .github/workflows/maven.yml → .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@

name: Reposilite CI

on:
push:
branches: [ master ]
branches: [ master, main, "3.0" ]
pull_request:
branches: [ master ]
branches: [ master, main, "3.0" ]

jobs:
build:
Expand All @@ -19,7 +21,9 @@ jobs:
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.jdk }}
- name: Build with Maven
run: sudo mvn package --file pom.xml
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew build
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ stats.dat
maven-metadata.xml*

### Maven ###
build/
target/
pom.xml.tag
pom.xml.releaseBackup
Expand Down
20 changes: 5 additions & 15 deletions .run/Reposilite.run.xml
Original file line number Diff line number Diff line change
@@ -1,21 +1,11 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Reposilite" type="Application" factoryName="Application">
<configuration default="false" name="Reposilite" type="Application" factoryName="Application" singleton="false">
<option name="ALTERNATIVE_JRE_PATH" value="8" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
<option name="MAIN_CLASS_NAME" value="org.panda_lang.reposilite.ReposiliteLauncher" />
<module name="reposilite" />
<option name="VM_PARAMETERS" value="-Xmx12M -Dreposilite.debugEnabled=true" />
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$/reposilite-backend/src/test/workspace" />
<method v="2">
<option name="Make" enabled="true" />
</method>
</configuration>
<configuration default="false" name="Reposilite" type="Application" factoryName="Application">
<option name="ALTERNATIVE_JRE_PATH" value="C:\Program Files\Java\jdk-16" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
<option name="MAIN_CLASS_NAME" value="org.panda_lang.reposilite.ReposiliteLauncher" />
<module name="reposilite" />
<option name="VM_PARAMETERS" value="-Xmx32M -Dreposilite.debugEnabled=true -Dtinylog.writerActive.level=DEBUG" />
<option name="MAIN_CLASS_NAME" value="com.reposilite.ReposiliteLauncherKt" />
<module name="reposilite-parent.reposilite-backend.main" />
<option name="PROGRAM_PARAMETERS" value="--token name:secret" />
<option name="VM_PARAMETERS" value="-Xmx16M -Dreposilite.debugEnabled=true -Dtinylog.writerActive.level=DEBUG" />
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$/reposilite-backend/src/test/workspace" />
<method v="2">
<option name="Make" enabled="true" />
Expand Down
11 changes: 6 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Build stage
FROM maven:3.6.3-openjdk-14-slim AS build
COPY ./ /app/
RUN mvn -f /app/pom.xml clean package
FROM gradle:7.0.2-jdk16 AS build
COPY --chown=gradle:gradle . /home/gradle/src
WORKDIR /home/gradle/src
RUN gradle build --no-daemon

# Build-time metadata stage
ARG BUILD_DATE
Expand All @@ -18,10 +19,10 @@ LABEL org.label-schema.build-date=$BUILD_DATE \
org.label-schema.schema-version="1.0"

# Run stage
FROM openjdk:15-alpine
FROM openjdk:16-alpine
RUN apk add --no-cache mailcap
WORKDIR /app
RUN mkdir -p /app/data
VOLUME /app/data
COPY --from=build /app/reposilite-backend/target/reposilite*.jar reposilite.jar
COPY --from=build /home/gradle/src/reposilite-backend/build/libs/*.jar reposilite.jar
ENTRYPOINT exec java $JAVA_OPTS -jar reposilite.jar -wd=/app/data $REPOSILITE_OPTS
38 changes: 32 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Reposilite [![Docker Pulls](https://img.shields.io/docker/pulls/dzikoysk/reposilite.svg?label=pulls&logo=docker)](https://hub.docker.com/r/dzikoysk/reposilite) [![Reposilite CI](https://github.com/dzikoysk/reposilite/actions/workflows/maven.yml/badge.svg)](https://github.com/dzikoysk/reposilite/actions/workflows/maven.yml) [![codecov](https://codecov.io/gh/dzikoysk/reposilite/branch/master/graph/badge.svg?token=9flNHTSJpp)](https://codecov.io/gh/dzikoysk/reposilite) [![Language grade: JavaScript](https://img.shields.io/lgtm/grade/javascript/g/dzikoysk/reposilite.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/dzikoysk/reposilite/context:javascript) [![CodeFactor](https://www.codefactor.io/repository/github/dzikoysk/reposilite/badge/master)](https://www.codefactor.io/repository/github/dzikoysk/reposilite/overview/master)
# Reposilite [![Docker Pulls](https://img.shields.io/docker/pulls/dzikoysk/reposilite.svg?label=pulls&logo=docker)](https://hub.docker.com/r/dzikoysk/reposilite) [![Reposilite CI](https://github.com/dzikoysk/reposilite/actions/workflows/gradle.yml/badge.svg)](https://github.com/dzikoysk/reposilite/actions/workflows/gradle.yml) [![codecov](https://codecov.io/gh/dzikoysk/reposilite/branch/master/graph/badge.svg?token=9flNHTSJpp)](https://codecov.io/gh/dzikoysk/reposilite) [![CodeFactor](https://www.codefactor.io/repository/github/dzikoysk/reposilite/badge/master)](https://www.codefactor.io/repository/github/dzikoysk/reposilite/overview/master) [![Discord Online](https://img.shields.io/discord/204728244434501632.svg)](https://discord.gg/qGRqmGjUFX) [![Discord](https://img.shields.io/badge/discord-reposilite-738bd7.svg?style=square)](https://discord.gg/qGRqmGjUFX)

[Reposilite](https://reposilite.com) *(formerly NanoMaven)* - lightweight repository manager for Maven based artifacts.
It is a simple solution to replace managers like Nexus, Archiva or Artifactory.
Expand All @@ -13,11 +13,11 @@ Demo: [repo.panda-lang.org](https://repo.panda-lang.org) <br>

Requirements:
* Java 8+
* RAM 12MB+
* RAM 16MB+

| Amount | Description |
|:------:|-------------|
| *12MB* | Tiny repository for personal projects |
| *16MB* | Tiny repository for personal projects |
| *16MB* - *32MB* | *--------------------^------------------* + CI + Proxy |
| *48MB - 128MB* | Tiny public repository *(recommended)* |
| *128MB+* | Public repository |
Expand All @@ -26,6 +26,11 @@ Requirements:
* [Reposilite - Official Guide](https://reposilite.com/docs/about)
* [Publishing your artifacts to the Reposilite - a new self-hosted repository manager ](https://dev.to/dzikoysk/publishing-your-artifacts-to-the-reposilite-a-new-self-hosted-repository-manager-3n0h)

Users' stories

* [Reposilite - Reddit Thread](https://www.reddit.com/r/java/comments/k8i2m0/reposilite_alternative_lightweight_maven/)
* [Looking for simple repository manager by David Kihato](https://kihats.medium.com/custom-self-hosted-maven-repository-cbb778031f68)

#### Features
* [x] Working Maven repository manager *(example: [repo.panda-lang.org](https://repo.panda-lang.org))*
* [x] Support Maven, Gradle and SBT build tools
Expand All @@ -36,7 +41,7 @@ Requirements:
* [x] Supports distributed environments like [K8s](https://github.com/dzikoysk/reposilite/issues/251#issuecomment-698974936)
* [x] Multithreading
* [x] Proxy of other remote repositories
* [x] Supports requests to primary repository without its name in url
* [x] Support requests to primary repository without its name in url
* [x] Dashboard
* [x] Customizable front page
* [x] Command line interface
Expand All @@ -49,7 +54,28 @@ Requirements:
* [x] 90%+ test coverage
* [x] Documentation

#### Supporters
Thanks to:

* [zzmgck](https://github.com/zzmgck) with $191
* [milkyway0308](https://github.com/milkyway0308) with $15
* Rob with $5
* ...

Reposilite is an implicit part of [panda-lang](https://github.com/panda-lang) organization.
To make a donation, visit [panda-lang.org/support](https://panda-lang.org/support) and use 'Reposilite' keyword in payment description ❤️.

#### Stack
* Reposilite Backend: Java + Javalin (Jetty) + Groovy (JUnit)
* Reposilite Frontend: Vue.js + Pug + Stylus + Tailwindcss

Reposilite 3.x
* Reposilite Backend: Kotlin + Javalin + Exposed + JUnit + _(DDD + Hexagonal Architecture)_
* Reposilite Frontend: Vue3 + Vite + Windicss
* Reposilite Site: React.js + Docusaurus

Reposilite 2.x
* Reposilite Backend: Java + Javalin (Jetty) + Groovy (JUnit) + _(DDD)_
* Reposilite Frontend: Vue2 + Pug + Stylus + Tailwindcss
* Reposilite Site: React.js + Docusaurus

Reposilite 1.x
* Reposilite: Java + NanoHTTPD _(and that's literally all)_
47 changes: 47 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/*
* Copyright (c) 2021 dzikoysk
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

plugins {
kotlin("jvm") version "1.5.21"
`maven-publish`
}

allprojects {
group = "org.panda-lang"
version = "3.0.0-SNAPSHOT"

apply(plugin = "maven-publish")

publishing {
repositories {
maven {
credentials {
username = property("mavenUser") as String
password = property("mavenPassword") as String
}
name = "panda-repository"
url = uri("https://repo.panda-lang.org/releases")
}
}
}

repositories {
mavenCentral()
maven { url = uri("https://repo.panda-lang.org/releases") }
maven { url = uri("https://s01.oss.sonatype.org/content/repositories/releases/") }
maven { url = uri("https://jitpack.io") }
}
}
2 changes: 1 addition & 1 deletion codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ codecov:
require_ci_to_pass: false

coverage:
range: 10..60
range: 10..50
round: up
precision: 2

Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: "3.9"
services:
reposilite:
image: reposilite:2.9.24
image: reposilite:3.0.0-SNAPSHOT
build:
context: .
dockerfile: Dockerfile
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/about.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge"/><title>About · Reposilite</title><meta name="viewport" content="width=device-width"/><meta name="generator" content="Docusaurus"/><meta name="description" content="Reposilite *(formerly NanoMaven)* is lightweight repository manager for Maven artifacts. It is a simple solution to replace managers like Nexus, Archiva or Artifactory."/><meta name="docsearch:language" content="en"/><meta property="og:title" content="About · Reposilite"/><meta property="og:type" content="website"/><meta property="og:url" content="https://reposilite.com/"/><meta property="og:description" content="Reposilite *(formerly NanoMaven)* is lightweight repository manager for Maven artifacts. It is a simple solution to replace managers like Nexus, Archiva or Artifactory."/><meta property="og:image" content="https://reposilite.com/img/undraw_online.svg"/><meta name="twitter:card" content="summary"/><meta name="twitter:image" content="https://reposilite.com/img/undraw_tweetstorm.svg"/><link rel="shortcut icon" href="/img/favicon.png"/><link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/idea.min.css"/><script type="text/javascript" src="https://buttons.github.io/buttons.js"></script><script src="/js/scrollSpy.js"></script><link rel="stylesheet" href="/css/main.css"/><script src="/js/codetabs.js"></script></head><body class="sideNavVisible separateOnPageNav"><div class="fixedHeaderContainer"><div class="headerWrapper wrapper"><header><a href="/"><h2 class="headerTitle">Reposilite</h2></a><div class="navigationWrapper navigationSlider"><nav class="slidingNav"><ul class="nav-site nav-site-internal"><li class="siteNavGroupActive siteNavItemActive"><a href="/docs/about" target="_self">Guide</a></li><li class=""><a href="/help" target="_self">Help</a></li><li class=""><a href="https://panda-lang.org/support" target="_self">Support</a></li><li class=""><a href="https://github.com/dzikoysk/reposilite" target="_self">GitHub</a></li></ul></nav></div></header></div></div><div class="navPusher"><div class="docMainWrapper wrapper"><div class="docsNavContainer" id="docsNav"><nav class="toc"><div class="toggleNav"><section class="navWrapper wrapper"><div class="navBreadcrumb wrapper"><div class="navToggle" id="navToggler"><div class="hamburger-menu"><div class="line1"></div><div class="line2"></div><div class="line3"></div></div></div><h2><i></i><span>Introduction</span></h2><div class="tocToggler" id="tocToggler"><i class="icon-toc"></i></div></div><div class="navGroups"><div class="navGroup"><h3 class="navGroupCategoryTitle">Introduction</h3><ul class=""><li class="navListItem navListItemActive"><a class="navItem" href="/docs/about">About</a></li><li class="navListItem"><a class="navItem" href="/docs/install">Installation</a></li><li class="navListItem"><a class="navItem" href="/docs/authorization">Authorization</a></li><li class="navListItem"><a class="navItem" href="/docs/deploy">Deploy</a></li><li class="navListItem"><a class="navItem" href="/docs/faq">FAQ</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Services</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/docker">Docker</a></li><li class="navListItem"><a class="navItem" href="/docs/cdn">CDN</a></li><li class="navListItem"><a class="navItem" href="/docs/reverse-proxy">Reverse proxy</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Settings</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/configuration">Configuration</a></li><li class="navListItem"><a class="navItem" href="/docs/repositories">Repositories</a></li><li class="navListItem"><a class="navItem" href="/docs/proxy">Proxy and caching</a></li><li class="navListItem"><a class="navItem" href="/docs/customization">Customization</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Dashboard</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/file-browser">File browser</a></li><li class="navListItem"><a class="navItem" href="/docs/remote-cli">Remote CLI</a></li><li class="navListItem"><a class="navItem" href="/docs/manual-deploy">Manual deploy</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Developers</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/indexing">Indexing</a></li><li class="navListItem"><a class="navItem" href="/docs/remote-execution">Remote execution</a></li></ul></div></div></section></div><script>
<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta http-equiv="X-UA-Compatible" content="IE=edge"/><title>About · Reposilite</title><meta name="viewport" content="width=device-width"/><meta name="generator" content="Docusaurus"/><meta name="description" content="Reposilite *(formerly NanoMaven)* is lightweight repository manager for Maven artifacts. It is a simple solution to replace managers like Nexus, Archiva or Artifactory."/><meta name="docsearch:language" content="en"/><meta property="og:title" content="About · Reposilite"/><meta property="og:type" content="website"/><meta property="og:url" content="https://reposilite.com/"/><meta property="og:description" content="Reposilite *(formerly NanoMaven)* is lightweight repository manager for Maven artifacts. It is a simple solution to replace managers like Nexus, Archiva or Artifactory."/><meta property="og:image" content="https://reposilite.com/img/undraw_online.svg"/><meta name="twitter:card" content="summary"/><meta name="twitter:image" content="https://reposilite.com/img/undraw_tweetstorm.svg"/><link rel="shortcut icon" href="/img/favicon.png"/><link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/idea.min.css"/><script type="text/javascript" src="https://buttons.github.io/buttons.js"></script><script src="/js/scrollSpy.js"></script><link rel="stylesheet" href="/css/main.css"/><script src="/js/codetabs.js"></script></head><body class="sideNavVisible separateOnPageNav"><div class="fixedHeaderContainer"><div class="headerWrapper wrapper"><header><a href="/"><h2 class="headerTitle">Reposilite</h2></a><div class="navigationWrapper navigationSlider"><nav class="slidingNav"><ul class="nav-site nav-site-internal"><li class="siteNavGroupActive siteNavItemActive"><a href="/docs/about" target="_self">Guide</a></li><li class=""><a href="/help" target="_self">Help</a></li><li class=""><a href="https://panda-lang.org/support" target="_self">Support</a></li><li class=""><a href="https://github.com/dzikoysk/reposilite" target="_self">GitHub</a></li></ul></nav></div></header></div></div><div class="navPusher"><div class="docMainWrapper wrapper"><div class="docsNavContainer" id="docsNav"><nav class="toc"><div class="toggleNav"><section class="navWrapper wrapper"><div class="navBreadcrumb wrapper"><div class="navToggle" id="navToggler"><div class="hamburger-menu"><div class="line1"></div><div class="line2"></div><div class="line3"></div></div></div><h2><i></i><span>Introduction</span></h2><div class="tocToggler" id="tocToggler"><i class="icon-toc"></i></div></div><div class="navGroups"><div class="navGroup"><h3 class="navGroupCategoryTitle">Introduction</h3><ul class=""><li class="navListItem navListItemActive"><a class="navItem" href="/docs/about">About</a></li><li class="navListItem"><a class="navItem" href="/docs/install">Installation</a></li><li class="navListItem"><a class="navItem" href="/docs/authorization">Authorization</a></li><li class="navListItem"><a class="navItem" href="/docs/deploy">Deploy</a></li><li class="navListItem"><a class="navItem" href="/docs/faq">FAQ</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Services</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/docker">Docker</a></li><li class="navListItem"><a class="navItem" href="/docs/cdn">CDN</a></li><li class="navListItem"><a class="navItem" href="/docs/reverse-proxy">Reverse proxy</a></li><li class="navListItem"><a class="navItem" href="/docs/systemd">Systemd</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Settings</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/configuration">Configuration</a></li><li class="navListItem"><a class="navItem" href="/docs/repositories">Repositories</a></li><li class="navListItem"><a class="navItem" href="/docs/proxy">Proxy and caching</a></li><li class="navListItem"><a class="navItem" href="/docs/customization">Customization</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Dashboard</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/file-browser">File browser</a></li><li class="navListItem"><a class="navItem" href="/docs/remote-cli">Remote CLI</a></li><li class="navListItem"><a class="navItem" href="/docs/manual-deploy">Manual deploy</a></li></ul></div><div class="navGroup"><h3 class="navGroupCategoryTitle">Developers</h3><ul class=""><li class="navListItem"><a class="navItem" href="/docs/indexing">Indexing</a></li><li class="navListItem"><a class="navItem" href="/docs/remote-execution">Remote execution</a></li></ul></div></div></section></div><script>
var coll = document.getElementsByClassName('collapsible');
var checkActiveCategory = true;
for (var i = 0; i < coll.length; i++) {
Expand Down
Loading

0 comments on commit c72189a

Please sign in to comment.