-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
QD-4594 Set up contributing guide and
bake
for fast local builds
- Loading branch information
Showing
13 changed files
with
103 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,7 @@ jobs: | |
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
# - name: Hadolint | ||
# uses: hadolint/[email protected] | ||
# with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
ARG NODE_TAG="16-bullseye-slim" | ||
ARG BASE_TAG="6.0-bullseye-slim" | ||
|
||
ARG DOTNET_BASE_TAG="6.0-bullseye-slim" | ||
FROM node:$NODE_TAG AS node_base | ||
FROM mcr.microsoft.com/dotnet/sdk:$BASE_TAG | ||
FROM mcr.microsoft.com/dotnet/sdk:$DOTNET_BASE_TAG | ||
|
||
ENV HOME="/root" \ | ||
LC_ALL="en_US.UTF-8" \ | ||
|
@@ -63,8 +62,8 @@ RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \ | |
npm install -g [email protected] [email protected] && npm config set update-notifier false && \ | ||
chmod 777 -R "$HOME/.npm" "$HOME/.npmrc" | ||
|
||
ARG QD_BUILD="QDNET-2023.2" | ||
ARG QD_RELEASE="2023.2" | ||
ARG QD_BUILD="QDNET-$QD_RELEASE" | ||
# hadolint ignore=DL3003,SC2043 | ||
RUN set -ex && \ | ||
dpkgArch="$(dpkg --print-architecture)" && \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
ARG GO_TAG="1.19-bullseye" | ||
ARG NODE_TAG="16-bullseye-slim" | ||
ARG BASE_TAG="1.19-bullseye" | ||
|
||
FROM node:$NODE_TAG AS node_base | ||
FROM golang:$BASE_TAG | ||
FROM golang:$GO_TAG | ||
|
||
ENV HOME="/root" \ | ||
LC_ALL="en_US.UTF-8" \ | ||
|
@@ -47,8 +46,8 @@ RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \ | |
npm install -g [email protected] [email protected] && npm config set update-notifier false && \ | ||
chmod 777 -R "$HOME/.npm" "$HOME/.npmrc" | ||
|
||
ARG QD_BUILD="QDGO-2023.2" | ||
ARG QD_RELEASE="2023.2" | ||
ARG QD_BUILD="QDGO-$QD_RELEASE" | ||
# hadolint ignore=DL3003,SC2043 | ||
RUN set -ex && \ | ||
dpkgArch="$(dpkg --print-architecture)" && \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
ARG NODE_TAG="16-bullseye-slim" | ||
ARG BASE_TAG="8.1-cli-bullseye" | ||
|
||
ARG PHP_TAG="8.1-cli-bullseye" | ||
ARG COMPOSER_TAG="2.5.1" | ||
FROM node:$NODE_TAG AS node_base | ||
FROM php:$BASE_TAG | ||
FROM composer:$COMPOSER_TAG AS composer_base | ||
FROM php:$PHP_TAG | ||
|
||
ENV HOME="/root" \ | ||
LC_ALL="en_US.UTF-8" \ | ||
|
@@ -35,10 +36,10 @@ RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=locked \ | |
git config --global --add safe.directory '*' | ||
|
||
ENV PATH="/opt/yarn/bin:$PATH" | ||
COPY --from=node:16-bullseye-slim /usr/local/bin/node /usr/local/bin/ | ||
COPY --from=node:16-bullseye-slim /usr/local/include/node /usr/local/include/node | ||
COPY --from=node:16-bullseye-slim /usr/local/lib/node_modules /usr/local/lib/node_modules | ||
COPY --from=node:16-bullseye-slim /opt/yarn-* /opt/yarn/ | ||
COPY --from=node_base /usr/local/bin/node /usr/local/bin/ | ||
COPY --from=node_base /usr/local/include/node /usr/local/include/node | ||
COPY --from=node_base /usr/local/lib/node_modules /usr/local/lib/node_modules | ||
COPY --from=node_base /opt/yarn-* /opt/yarn/ | ||
RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \ | ||
ln -s /usr/local/lib/node_modules/npm/bin/npx-cli.js /usr/local/bin/npx && \ | ||
ln -s /usr/local/lib/node_modules/corepack/dist/corepack.js /usr/local/bin/corepack && \ | ||
|
@@ -48,10 +49,10 @@ RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \ | |
npm install -g [email protected] [email protected] && npm config set update-notifier false && \ | ||
chmod 777 -R "$HOME/.npm" "$HOME/.npmrc" | ||
|
||
COPY --from=composer:2.5.1 /usr/bin/composer /usr/bin/composer | ||
COPY --from=composer_base /usr/bin/composer /usr/bin/composer | ||
|
||
ARG QD_BUILD="QDPHP-2023.2" | ||
ARG QD_RELEASE="2023.2" | ||
ARG QD_BUILD="QDPHP-$QD_RELEASE" | ||
# hadolint ignore=DL3003,SC2043 | ||
RUN set -ex && \ | ||
dpkgArch="$(dpkg --print-architecture)" && \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
ARG BASE_TAG="bullseye-slim" | ||
ARG NODE_TAG="16-bullseye-slim" | ||
FROM node:$NODE_TAG AS node_base | ||
FROM debian:$BASE_TAG | ||
|
||
ENV HOME="/root" \ | ||
|
@@ -71,10 +73,10 @@ RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=locked \ | |
rm -rf /tmp/* | ||
|
||
ENV PATH="/opt/yarn/bin:$PATH" | ||
COPY --from=node:16-bullseye-slim /usr/local/bin/node /usr/local/bin/ | ||
COPY --from=node:16-bullseye-slim /usr/local/include/node /usr/local/include/node | ||
COPY --from=node:16-bullseye-slim /usr/local/lib/node_modules /usr/local/lib/node_modules | ||
COPY --from=node:16-bullseye-slim /opt/yarn-* /opt/yarn/ | ||
COPY --from=node_base /usr/local/bin/node /usr/local/bin/ | ||
COPY --from=node_base /usr/local/include/node /usr/local/include/node | ||
COPY --from=node_base /usr/local/lib/node_modules /usr/local/lib/node_modules | ||
COPY --from=node_base /opt/yarn-* /opt/yarn/ | ||
RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \ | ||
ln -s /usr/local/lib/node_modules/npm/bin/npx-cli.js /usr/local/bin/npx && \ | ||
ln -s /usr/local/lib/node_modules/corepack/dist/corepack.js /usr/local/bin/corepack && \ | ||
|
@@ -84,8 +86,8 @@ RUN ln -s /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm && \ | |
npm install -g [email protected] [email protected] && npm config set update-notifier false && \ | ||
chmod 777 -R "$HOME/.npm" "$HOME/.npmrc" | ||
|
||
ARG QD_BUILD="QDPY-2023.2" | ||
ARG QD_RELEASE="2023.2" | ||
ARG QD_BUILD="QDPY-$QD_RELEASE" | ||
# hadolint ignore=DL3003,SC2043 | ||
RUN set -ex && \ | ||
dpkgArch="$(dpkg --print-architecture)" && \ | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Contributing | ||
|
||
By participating in this project, you agree to abide our [Code of conduct](.github/CODE_OF_CONDUCT.md). | ||
|
||
## Set up your machine | ||
|
||
Prerequisites: | ||
|
||
- [Docker](https://docs.docker.com/get-docker/) | ||
|
||
Other things you might need to develop: | ||
|
||
- [IntelliJ IDEA](https://www.jetbrains.com/idea/) (it's [free for open-source development](https://www.jetbrains.com/community/opensource/)) | ||
|
||
Clone the project anywhere: | ||
|
||
```sh | ||
git clone [email protected]:JetBrains/qodana-docker.git | ||
``` | ||
|
||
`cd` into the directory, with [Docker Bake](https://docs.docker.com/build/bake/) you can build all images at once: | ||
|
||
```shell | ||
docker buildx bake | ||
``` | ||
|
||
## Create a commit | ||
|
||
Commit messages should be well formatted, and to make that "standardized", we are using [internal issue tracker](https://youtrack.jetbrains.com) references. | ||
|
||
|
||
## Submit a pull request | ||
|
||
Push your branch to your repository fork and open a pull request against the | ||
main branch. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
group "default" { | ||
targets = ["232"] | ||
} | ||
|
||
target "232" { | ||
name = "qodana-${edition}" | ||
matrix = { | ||
edition = ["android-community", "dotnet", "go", "js", "jvm", "jvm-community", "php", "python", "python-community"] | ||
version = ["2023.2"] | ||
} | ||
args = { | ||
QD_RELEASE = "2023.2" | ||
BASE_TAG = "bullseye-slim" | ||
DOTNET_TAG = "6.0-bullseye-slim" | ||
GO_TAG = "1.19-bullseye" | ||
NODE_TAG = "16-bullseye-slim" | ||
PHP_TAG = "8.1-cli-bullseye" | ||
COMPOSER_TAG="2.5.1" | ||
} | ||
tags = [ | ||
"docker.io/jetbrains/qodana:${edition}-${version}-latest" | ||
] | ||
# platforms = ["linux/amd64", "linux/arm64"] // uncomment to build for multiple platforms, but it will take more time | ||
dockerfile = "${version}/${edition}/Dockerfile" | ||
} |