diff --git a/.github/workflows/build-docker.yml b/.github/workflows/build-docker.yml index 44af6d17..3ff963b0 100644 --- a/.github/workflows/build-docker.yml +++ b/.github/workflows/build-docker.yml @@ -27,7 +27,7 @@ jobs: username: ${{ secrets.DOCKER_HUB_USERNAME }} password: ${{ secrets.DOCKER_HUB_TOKEN }} - - name: Login to DockerHub + - name: Login to GitHub Registry uses: docker/login-action@v3 with: registry: ghcr.io @@ -38,9 +38,10 @@ jobs: id: prep run: | DOCKER_IMAGE=linkace/linkace - DOCKER_IMAGE_GITUHB=ghcr.io/kovah/linkace + DOCKER_IMAGE_GITHUB=ghcr.io/kovah/linkace + MAJOR_VERSION=1.x VERSION=${GITHUB_REF#refs/tags/} - TAGS="${DOCKER_IMAGE}:${VERSION},${DOCKER_IMAGE}:latest,${DOCKER_IMAGE_GITUHB}:${VERSION},${DOCKER_IMAGE_GITUHB}:latest" + TAGS="${DOCKER_IMAGE}:${VERSION},${DOCKER_IMAGE}:${MAJOR_VERSION},${DOCKER_IMAGE}:latest,${DOCKER_IMAGE_GITHUB}:${VERSION},${DOCKER_IMAGE_GITHUB}:${MAJOR_VERSION},${DOCKER_IMAGE_GITHUB}:latest" echo "tags=${TAGS}" >> $GITHUB_OUTPUT - name: Build and push advanced image @@ -58,7 +59,8 @@ jobs: DOCKER_IMAGE=linkace/linkace DOCKER_IMAGE_GITHUB=ghcr.io/kovah/linkace VERSION=${GITHUB_REF#refs/tags/} - TAGS="${DOCKER_IMAGE}:${VERSION}-php-nginx,${DOCKER_IMAGE}:php-nginx,${DOCKER_IMAGE}:${VERSION}-simple,${DOCKER_IMAGE}:simple,${DOCKER_IMAGE_GITHUB}:${VERSION}-php-nginx,${DOCKER_IMAGE_GITHUB}:php-nginx,${DOCKER_IMAGE_GITHUB}:${VERSION}-simple,${DOCKER_IMAGE_GITHUB}:simple" + MAJOR_VERSION=1.x + TAGS="${DOCKER_IMAGE}:${VERSION}-php-nginx,${DOCKER_IMAGE}:${MAJOR_VERSION}-php-nginx,${DOCKER_IMAGE}:php-nginx,${DOCKER_IMAGE}:${VERSION}-simple,${DOCKER_IMAGE}:${MAJOR_VERSION}-simple,${DOCKER_IMAGE}:simple,${DOCKER_IMAGE_GITHUB}:${VERSION}-php-nginx,${DOCKER_IMAGE_GITHUB}:${MAJOR_VERSION}-php-nginx,${DOCKER_IMAGE_GITHUB}:php-nginx,${DOCKER_IMAGE_GITHUB}:${VERSION}-simple,${DOCKER_IMAGE_GITHUB}:${MAJOR_VERSION}-simple,${DOCKER_IMAGE_GITHUB}:simple" echo "tags=${TAGS}" >> $GITHUB_OUTPUT - name: Build and push simple image diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 012ebf50..022a67d2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,36 +1,39 @@ # :construction: Contribution -If you want to contribute to the project please open a [ticket](https://github.com/Kovah/LinkAce/issues) first and -describe what you want to do or what your idea is. Maybe there already is an existing ticket for your or a very similar +If you want to contribute to the project please open an [issue](https://github.com/Kovah/LinkAce/issues) first and +describe what you want to do or what your idea is. Maybe there already is an existing issue for your or a very similar topic. I may decline contributions for features that may not fit into the application, so please make sure to talk to me before starting to code. - ## Contribution Guidelines -* Always use the `dev` branch to work on the application. The dev branch will contain the latest version of the app - while the `main` branch contains the stable version (which may be outdated in terms of development). -* Consider using a separate branch if you are working on a larger feature. +* LinkAce uses two primary branches for the different major versions: + * `1.x` + * `2.x` +* Those two branches hold the latest nightly (i.e. possibly unstable) code for the respective version. The latest stable + version is accessible through the releases section and the corresponding tag. +* Use the appropriate branch as a starting point for your contribution. Then open a pull request with your changes. * Reference the issue number in your commits please. -* When opening a pull request, link to your ticket and describe what you did to solve the problem. - +* When opening a pull request, link to your issue and describe what you did to solve the problem. --- - ## Development ### Minimum Requirements * [Docker](https://www.docker.com/products/docker-desktop)/[Podman](https://podman.io/docs/installation) _or_ a [currently-supported PHP version](https://www.php.net/supported-versions.php) * For Podman, you also need to `apt`, `dnf`, or otherwise install [`podman-compose`](https://github.com/containers/podman-compose) -* [Node](https://nodejs.org/en/) (16 LTS) +* [Node](https://nodejs.org/en/) (20 LTS) ### 1. Basic Setup -The following steps assume that you are using Docker or Podman for development, which I highly encourage. If you use other ways to work with PHP projects you must adapt the commands to your system. If you want to use Podman, simply replace the word `docker` with `podman` in each command. Clone the repository to your machine and run the following commands to start the Docker container system: +The following steps assume that you are using Docker or Podman for development, which I highly encourage. If you use +other ways to work with PHP projects you must adapt the commands to your system. If you want to use Podman, simply +replace the word `docker` with `podman` in each command. Clone the repository to your machine and run the following +commands to start the Docker container system: ```bash cp .env.docker .env @@ -45,7 +48,8 @@ docker compose exec -it php composer install docker compose exec -it php php artisan key:generate ``` -Last step: compile all assets. Node 16 LTS is the minimum version required and recommended to use. You may use either NPM or Yarn for installing the asset dependencies. +Last step: compile all assets. Node 16 LTS is the minimum version required and recommended to use. You may use either +NPM or Yarn for installing the asset dependencies. ```bash npm install @@ -55,7 +59,8 @@ npm run dev #### 2. Working with the Artisan command line -I recommend using the Artisan command line tool in the PHP container only, to make sure that the same environment is used. To do so, use the following example command: +I recommend using the Artisan command line tool in the PHP container only, to make sure that the same environment is +used. To do so, use the following example command: ```bash docker compose exec -it php php artisan migrate @@ -69,7 +74,6 @@ Currently, you can do this by using the command line: docker compose exec -it php php artisan registeruser [user name] [user email] ``` - ## Tests You can run existing tests with the following command: @@ -79,10 +83,13 @@ docker compose exec -it php composer run lint docker compose exec -it php composer run test ``` +--- ## LinkAce Base Docker image -The Base image for LinkAce contains several packages and PHP extensions needed by LinkAce. It shortens the build time of the release images. This step is not needed by any developer working on LinkAce and is just a documentation for maintainers. +The Base image for LinkAce contains several packages and PHP extensions needed by LinkAce. It shortens the build time of +the release images. This step is not needed by any developer working on LinkAce and is just a documentation for +maintainers. ```bash docker buildx build --push --platform "linux/amd64,linux/arm64,linux/arm/v7" -t linkace/base-image:php-8.3-alpine -f resources/docker/dockerfiles/release-base.Dockerfile . diff --git a/README.md b/README.md index d1f6fc93..ac348e2c 100644 --- a/README.md +++ b/README.md @@ -5,8 +5,8 @@

Your self-hosted bookmark archive.

- Follow LinkAce on Twitter - Docker Repository + Follow LinkAce on X.com + Follow LinkAce on Mastodon Latest Release License

@@ -38,7 +38,7 @@ It provides a long-term archive to store links to websites, media files or anyth * Save links with automatic title and description generation. * Automated link monitoring informs you when any links become unavailable or were moved. -* Automated backups of saved sites via the [Internet Archive](https://web.archive.org/). +* Automated archiving of saved sites via the [Internet Archive](https://web.archive.org/). * Organize bookmarks with the help of lists and tags. * A full REST API offers access to all features of LinkAce from other apps and services. * LinkAce is also [available on Zapier](https://zapier.com/apps/linkace/integrations) and integrates with over 2500+ applications. @@ -72,7 +72,7 @@ LinkAce provides multiple ways of installing it on your server. The complete doc I built LinkAce to solve my own problem, and I now offer my solution and code without charging any money. I spent a lot of my free time building this application, so I won't offer any *free* personal support, customization or installation help. If you need help please visit the [community discussions](https://github.com/Kovah/LinkAce/discussions) and post your issue there. -You can get personal and dedicated support by **becoming a supporter on [Open Collective](https://opencollective.com/linkace), [Patreon](https://www.patreon.com/Kovah) or [Github](https://github.com/sponsors/Kovah)**. :star: +:star: You can get personal and dedicated support by **becoming a supporter on [Open Collective](https://opencollective.com/linkace), [Patreon](https://www.patreon.com/Kovah) or [Github](https://github.com/sponsors/Kovah)**. #### Our Supporters on Open Collective diff --git a/docker-compose.yml b/docker-compose.yml index 05267c36..e61b6de9 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -18,7 +18,7 @@ services: - linkace-db:/var/lib/mysql pg-db: - image: docker.io/library/postgres:14 + image: docker.io/library/postgres:16 environment: - POSTGRES_PASSWORD=${DB_PASSWORD} - POSTGRES_USER=${DB_USERNAME} diff --git a/package-lock.json b/package-lock.json index 017b5f25..15cfb9b1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "linkace", - "version": "1.15.0", + "version": "1.15.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "linkace", - "version": "1.15.0", + "version": "1.15.1", "license": "GPL-3.0-or-later", "dependencies": { "bootstrap": "^5.3.3", @@ -15,7 +15,7 @@ "devDependencies": { "laravel-mix": "^6.0.31", "postcss": "^8.4.35", - "sass": "^1.71.1", + "sass": "^1.77.8", "sass-loader": "^14.1.0" } }, @@ -7726,9 +7726,9 @@ "dev": true }, "node_modules/sass": { - "version": "1.77.6", - "resolved": "https://registry.npmjs.org/sass/-/sass-1.77.6.tgz", - "integrity": "sha512-ByXE1oLD79GVq9Ht1PeHWCPMPB8XHpBuz1r85oByKHjZY6qV6rWnQovQzXJXuQ/XyE1Oj3iPk3lo28uzaRA2/Q==", + "version": "1.77.8", + "resolved": "https://registry.npmjs.org/sass/-/sass-1.77.8.tgz", + "integrity": "sha512-4UHg6prsrycW20fqLGPShtEvo/WyHRVRHwOP4DzkUrObWoWI05QBSfzU71TVB7PFaL104TwNaHpjlWXAZbQiNQ==", "dev": true, "dependencies": { "chokidar": ">=3.0.0 <4.0.0", diff --git a/package.json b/package.json index e2487063..1d91b563 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "linkace", - "version": "1.15.0", + "version": "1.15.1", "description": "A small, selfhosted bookmark manager with advanced features, built with Laravel and Docker", "homepage": "https://github.com/Kovah/LinkAce", "repository": { @@ -15,7 +15,7 @@ "devDependencies": { "laravel-mix": "^6.0.31", "postcss": "^8.4.35", - "sass": "^1.71.1", + "sass": "^1.77.8", "sass-loader": "^14.1.0" }, "dependencies": { diff --git a/resources/docker/dockerfiles/development.Dockerfile b/resources/docker/dockerfiles/development.Dockerfile index 9e851bb7..1d3e7412 100644 --- a/resources/docker/dockerfiles/development.Dockerfile +++ b/resources/docker/dockerfiles/development.Dockerfile @@ -1,21 +1,18 @@ # DOCKERFILE DEVELOPMENT -# Installs MySQL Client for database exports, xDebug with PCov and Composer +# Installs database clients for database exports, xDebug with PCov and Composer -FROM docker.io/library/php:8.1.10-fpm +FROM docker.io/library/php:8.1-fpm-alpine WORKDIR /app -RUN apt-get update && apt-get install -y \ - zip \ - git \ - mariadb-client \ - autoconf \ - build-essential \ - libpq-dev \ - libzip-dev - -RUN pecl install xdebug pcov -RUN docker-php-ext-install bcmath pdo_mysql pdo_pgsql zip -RUN docker-php-ext-enable xdebug pcov +# Install package and PHP dependencies +RUN apk add --no-cache git mariadb-client postgresql-client postgresql-dev sqlite zip libzip-dev; \ + docker-php-ext-configure zip; \ + docker-php-ext-install bcmath pdo_mysql pdo_pgsql zip ftp; \ + docker-php-ext-enable xdebug pcov; \ + mkdir /ssl-certs; \ + docker-php-source delete; \ + rm -f /usr/src/php.tar.xz /usr/src/php.tar.xz.asc; \ + apk del --no-cache postgresql-dev RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer diff --git a/resources/docker/dockerfiles/release-base.Dockerfile b/resources/docker/dockerfiles/release-base.Dockerfile index c308e7d6..ac1a56b6 100644 --- a/resources/docker/dockerfiles/release-base.Dockerfile +++ b/resources/docker/dockerfiles/release-base.Dockerfile @@ -1,8 +1,10 @@ FROM docker.io/library/php:8.3-fpm-alpine # Install package and PHP dependencies -RUN apk add --no-cache mariadb-client postgresql postgresql-dev sqlite zip libzip-dev; \ +RUN apk add --no-cache mariadb-client postgresql-client postgresql-dev sqlite zip libzip-dev; \ docker-php-ext-configure zip; \ docker-php-ext-install bcmath pdo_mysql pdo_pgsql zip ftp; \ mkdir /ssl-certs; \ - docker-php-source delete + docker-php-source delete; \ + rm -f /usr/src/php.tar.xz /usr/src/php.tar.xz.asc; \ + apk del --no-cache postgresql-dev