Skip to content

Commit

Permalink
Introduce end-of-line normalization
Browse files Browse the repository at this point in the history
  • Loading branch information
runejo committed Dec 10, 2024
1 parent 656125c commit db2355c
Show file tree
Hide file tree
Showing 12 changed files with 462 additions and 462 deletions.
56 changes: 28 additions & 28 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
name: Docker CI build

on:
push:
branches: ['main']
pull_request:
branches: ['main']

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64
push: false
name: Docker CI build

on:
push:
branches: ['main']
pull_request:
branches: ['main']

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64
push: false
100 changes: 50 additions & 50 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
@@ -1,50 +1,50 @@
name: Docker build and publish

on:
release:
types:
- published

env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Log into registry ${{ env.REGISTRY }}
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}

- name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
name: Docker build and publish

on:
release:
types:
- published

env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Log into registry ${{ env.REGISTRY }}
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}

- name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
92 changes: 46 additions & 46 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,46 +1,46 @@
# Contributing to PxWeb

Thank you for your interest in contributing to PxWeb! We welcome contributions from the community to help improve our project.

## Getting Started
To get started with contributing, please follow these steps:

1. Fork the repository on GitHub.
2. Clone your forked repository to your local machine.
3. Create a new branch from the `main` branch. Name your branch descriptively, indicating the purpose of your changes.
4. Make your changes and ensure that the code follows the project's coding conventions.
5. Test your changes thoroughly to ensure they work as expected.
6. Commit your changes with a clear and descriptive commit message.
7. Push your changes to your forked repository.
8. Open a pull request against the `main` branch of the original repository.

## 3rd Party Components

While developing for this project, we aim to minimize the number of dependencies. This is to keep the project lightweight, maintainable, and to reduce potential security risks.

Before adding a new 3rd party component or library, please consider the following:

1. Is the component necessary? Can the functionality be achieved without it?
2. Is the component actively maintained? An unmaintained component can pose a security risk and may lack support.
3. Does the component have a large community? Larger communities often mean more resources for troubleshooting and learning.
4. Is the component's license compatible with our project?

If you believe a 3rd party component is necessary, please provide a justification in your pull request. The project maintainers will review and discuss the addition.

## Code Review

All pull requests will be reviewed by the project maintainers. Please be patient and responsive during the review process. Feedback and suggestions may be provided to help improve the quality of your contribution.

## Issue Tracking

If you encounter any issues or have ideas for improvements, please check the project's issue tracker on GitHub. If the issue or idea has not been reported yet, feel free to open a new issue.

## Code of Conduct

This project and everyone participating in it is governed by the [Contributor Covenant Code of Conduct](CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code.

## License

By contributing to this project, you agree that your contributions will be licensed under the [project's license](LICENSE).

We appreciate your contributions and look forward to working with you!
# Contributing to PxWeb

Thank you for your interest in contributing to PxWeb! We welcome contributions from the community to help improve our project.

## Getting Started
To get started with contributing, please follow these steps:

1. Fork the repository on GitHub.
2. Clone your forked repository to your local machine.
3. Create a new branch from the `main` branch. Name your branch descriptively, indicating the purpose of your changes.
4. Make your changes and ensure that the code follows the project's coding conventions.
5. Test your changes thoroughly to ensure they work as expected.
6. Commit your changes with a clear and descriptive commit message.
7. Push your changes to your forked repository.
8. Open a pull request against the `main` branch of the original repository.

## 3rd Party Components

While developing for this project, we aim to minimize the number of dependencies. This is to keep the project lightweight, maintainable, and to reduce potential security risks.

Before adding a new 3rd party component or library, please consider the following:

1. Is the component necessary? Can the functionality be achieved without it?
2. Is the component actively maintained? An unmaintained component can pose a security risk and may lack support.
3. Does the component have a large community? Larger communities often mean more resources for troubleshooting and learning.
4. Is the component's license compatible with our project?

If you believe a 3rd party component is necessary, please provide a justification in your pull request. The project maintainers will review and discuss the addition.

## Code Review

All pull requests will be reviewed by the project maintainers. Please be patient and responsive during the review process. Feedback and suggestions may be provided to help improve the quality of your contribution.

## Issue Tracking

If you encounter any issues or have ideas for improvements, please check the project's issue tracker on GitHub. If the issue or idea has not been reported yet, feel free to open a new issue.

## Code of Conduct

This project and everyone participating in it is governed by the [Contributor Covenant Code of Conduct](CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code.

## License

By contributing to this project, you agree that your contributions will be licensed under the [project's license](LICENSE).

We appreciate your contributions and look forward to working with you!
22 changes: 11 additions & 11 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
FROM node:20.18.0-slim AS build
WORKDIR /app
COPY . ./
RUN npm ci && npm run build

# production environment
FROM nginxinc/nginx-unprivileged:1.27.3-alpine3.20
COPY --from=build /app/packages/pxweb2/dist /usr/share/nginx/html
COPY nginx/conf.d/default.conf /etc/nginx/conf.d
EXPOSE 8080
CMD ["nginx", "-g", "daemon off;"]
FROM node:20.18.0-slim AS build
WORKDIR /app
COPY . ./
RUN npm ci && npm run build

# production environment
FROM nginxinc/nginx-unprivileged:1.27.3-alpine3.20
COPY --from=build /app/packages/pxweb2/dist /usr/share/nginx/html
COPY nginx/conf.d/default.conf /etc/nginx/conf.d
EXPOSE 8080
CMD ["nginx", "-g", "daemon off;"]
Loading

0 comments on commit db2355c

Please sign in to comment.