Commit Graph

290 Commits

Author SHA1 Message Date
Manav Rathi
2d16d958e3 [meta] Create custom codeql.yml
Here is the original autogenerated template from which this is based:

----

# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL Advanced"

on:
  push:
    branches: [ "main" ]
  pull_request:
    branches: [ "main" ]
  schedule:
    - cron: '22 1 * * 1'

jobs:
  analyze:
    name: Analyze (${{ matrix.language }})
    # Runner size impacts CodeQL analysis time. To learn more, please see:
    #   - https://gh.io/recommended-hardware-resources-for-running-codeql
    #   - https://gh.io/supported-runners-and-hardware-resources
    #   - https://gh.io/using-larger-runners (GitHub.com only)
    # Consider using larger runners or machines with greater resources for possible analysis time improvements.
    runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
    permissions:
      # required for all workflows
      security-events: write

      # required to fetch internal or private CodeQL packs
      packages: read

      # only required for workflows in private repositories
      actions: read
      contents: read

    strategy:
      fail-fast: false
      matrix:
        include:
        - language: actions
          build-mode: none
        - language: c-cpp
          build-mode: autobuild
        - language: go
          build-mode: autobuild
        - language: java-kotlin
          build-mode: autobuild
        - language: javascript-typescript
          build-mode: none
        - language: ruby
          build-mode: none
        - language: swift
          build-mode: autobuild
        # CodeQL supports the following values keywords for 'language': 'actions', 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift'
        # Use `c-cpp` to analyze code written in C, C++ or both
        # Use 'java-kotlin' to analyze code written in Java, Kotlin or both
        # Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
        # To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
        # see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
        # If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
        # your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
    steps:
    - name: Checkout repository
      uses: actions/checkout@v4

    # Add any setup steps before running the `github/codeql-action/init` action.
    # This includes steps like installing compilers or runtimes (`actions/setup-node`
    # or others). This is typically only required for manual builds.
    # - name: Setup runtime (example)
    #   uses: actions/setup-example@v1

    # Initializes the CodeQL tools for scanning.
    - name: Initialize CodeQL
      uses: github/codeql-action/init@v3
      with:
        languages: ${{ matrix.language }}
        build-mode: ${{ matrix.build-mode }}
        # If you wish to specify custom queries, you can do so here or in a config file.
        # By default, queries listed here will override any specified in a config file.
        # Prefix the list here with "+" to use these queries and those in the config file.

        # For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
        # queries: security-extended,security-and-quality

    # If the analyze step fails for one of the languages you are analyzing with
    # "We were unable to automatically build your code", modify the matrix above
    # to set the build mode to "manual" for that language. Then modify this step
    # to build your code.
    # ℹ️ Command-line programs to run using the OS shell.
    # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
    - if: matrix.build-mode == 'manual'
      shell: bash
      run: |
        echo 'If you are using a "manual" build mode for one or more of the' \
          'languages you are analyzing, replace this with the commands to build' \
          'your code, for example:'
        echo '  make bootstrap'
        echo '  make release'
        exit 1

    - name: Perform CodeQL Analysis
      uses: github/codeql-action/analyze@v3
      with:
        category: "/language:${{matrix.language}}"
2025-03-28 13:44:49 +05:30
Manav Rathi
cf7d46fd70 go-rel
ref: https://github.com/wangyoucao577/go-release-action?tab=readme-ov-file#basic-example
2025-03-28 13:02:19 +05:30
Manav Rathi
875a747e24 granular perms / release
"only required permissions for the action specified (which is contents: write)"
- https://github.com/ncipollo/release-action?tab=readme-ov-file#notes
2025-03-28 12:57:41 +05:30
Manav Rathi
0e4fa1ad4c ro 2025-03-28 12:57:41 +05:30
Manav Rathi
0f62c4fa79 granular perms / docker-push
ref: https://docs.github.com/en/packages/managing-github-packages-using-github-actions-workflows/publishing-and-installing-a-package-with-github-actions#authenticating-to-package-registries-with-repository-scoped-permissions
2025-03-28 12:32:33 +05:30
Manav Rathi
038f6b33e1 granular perms [crowdin] 2025-03-28 12:22:59 +05:30
Manav Rathi
1da0455b77 Add web variant 2025-03-20 11:03:53 +05:30
Manav Rathi
9222b029b2 Increas hamming distance 2025-03-20 10:54:11 +05:30
Manav Rathi
91494f7823 [server] Change server/ghcr => ghcr/server
In prep for its new baby sibling, ghcr/web.
2025-03-20 10:42:42 +05:30
Neeraj
2ccd92519b [auth] remove ubuntu-20.04 runner & more (#5232)
## Description

Remove deprecated ubuntu-20.04 workflow and merge it with the latest.

## Tests
2025-03-12 15:16:52 +05:30
Manav Rathi
511c324bad [web] Submodules required no more 2025-03-07 19:50:06 +05:30
Prateek Sunal
54c8d5851b [auth] fix(workflow): remove soon to be deprecated ubuntu-20.04 workflow and switch source to ente-io of flutter_distributor 2025-03-05 19:23:53 +05:30
Aman Raj Singh Mourya
d667cc4f98 [auth] Set cronetHttpNoPlay=true while building apk for droid 2025-02-22 00:48:53 +05:30
Manav Rathi
00a04f18e4 [server] Fix publish workflow
Fixes for https://github.com/ente-io/ente/pull/5088
2025-02-17 11:00:21 +05:30
Manav Rathi
91f356ceda [server] Publish Docker image automatically on 15th of every month 2025-02-17 10:51:23 +05:30
vishnukvmd
8a90eba39a Add webhook 2025-02-13 09:58:36 +05:30
vishnukvmd
562ead3202 [mob] Notify Discord when internal releases are ready 2025-02-13 09:56:25 +05:30
Neeraj Gupta
7621041ce0 Revert "[mob] Fix exif time parsing (#4985)"
This reverts commit 5b17711b55, reversing
changes made to 85bf3eebcb.
2025-02-11 18:27:17 +05:30
Neeraj Gupta
988a3e74b4 [auth] Downgrade flutter version 2025-01-28 14:53:12 +05:30
ashilkn
927267f19f [mob][photos] Revert to flutter 3.24.3 2025-01-24 12:21:26 +05:30
Neeraj Gupta
6eb381b64a [auth][photos] Upgrade flutter 2025-01-21 14:02:13 +05:30
Manav Rathi
a164f1b839 [web] Deploy only on weekdays 2025-01-17 14:48:12 +05:30
Neeraj Gupta
0c690efc38 [auth] Fix workflow for Ubuntu build 2025-01-14 09:04:47 +05:30
Neeraj Gupta
82225a0f2a [auth] Update Github build action 2025-01-14 08:48:22 +05:30
Neeraj Gupta
61e8a86ca5 [auth] Update Github build action 2025-01-14 08:41:21 +05:30
Manav Rathi
7d12141199 [meta] Need to qualify the ref to push from a detached HEAD 2025-01-08 15:44:14 +05:30
Rui Chen
2e517535b3 [cli] Switch to go v1.23 (#4556)
## Description

feat: update to use go1.23

---

relates to https://github.com/Homebrew/homebrew-core/pull/201919
(homebrew side always use latest go for building the artifact)

also love a new cli release for some patches so that we can proceed with
the homebrew PR

Signed-off-by: Rui Chen <rui@chenrui.dev>
2025-01-01 13:47:39 +05:30
Manav Rathi
182fd89356 [server] Retain published image commit as branch instead of tag
Overwriting tags is clunky (besides being generally discouraged). e.g. pulling
the overwritten tags locally requires `git fetch --force --tags`. So instead use
the branch `server/ghcr` to point to the commit from which the latest published
ghcr docker image has been built
2024-12-30 13:58:08 +05:30
Neeraj Gupta
4035e364df [auth] Update github workflow for auth-release 2024-12-21 16:56:47 +05:30
Neeraj Gupta
747bf88515 [auth] Lint on file size 2024-12-13 14:11:26 +05:30
Neeraj Gupta
e3a4f419f4 [auth] Move custom icon validation on top 2024-12-04 10:15:21 +05:30
Neeraj Gupta
71fcce5f01 [auth] Add Lint validation for custom icon name 2024-12-04 09:48:07 +05:30
Prateek Sunal
8bd6f23236 fix(workflow): remove libwebkit 2024-10-08 21:21:07 +05:30
Prateek Sunal
4c5942016f fix: make release path generic 2024-09-28 22:15:53 +05:30
Prateek Sunal
39765dd802 fix: path for release 2024-09-28 22:13:25 +05:30
Prateek Sunal
fa9d171287 Merge remote-tracking branch 'origin/main' into auth-linux-fixes 2024-09-27 00:25:15 +05:30
Prateek Sunal
484b05bdb2 fix: update receipe for linux and windows 2024-09-25 00:16:59 +05:30
Manav Rathi
bb0bdf113e [meta] [infra] Rename workflow file to use same extension as the rest 2024-09-19 17:13:11 +05:30
Neeraj Gupta
7d66b4c29f Use JAVA 17 for auth release workflow 2024-09-19 06:58:27 +05:30
Neeraj Gupta
b9eef77d3a [mob][auth] Upgrade flutter v3.24.3 2024-09-17 11:11:33 +05:30
Neeraj Gupta
d3b30052e2 [auth] Bump version 2024-09-13 18:08:05 +05:30
Neeraj Gupta
02d69b3b1c [auth] Add workflow for internal release 2024-09-13 17:43:07 +05:30
Manav Rathi
70dada90b2 [web][meta] Ignore stale lint runs on PR push
https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#example-using-concurrency-and-the-default-behavior
2024-09-10 13:02:12 +05:30
ashilkn
d413ed2de0 [mob][auth] Update flutter version in github workflows 2024-08-29 20:46:24 +05:30
Manav Rathi
ac5d37a9e3 Not helping, this is just causing it to run twice 2024-08-28 20:38:25 +05:30
Manav Rathi
cfe9178301 Experiment to try and reduce the latency 2024-08-27 20:00:38 +05:30
Neeraj Gupta
b9f8f55a30 [mob] Upgrade crowdin config 2024-08-27 15:59:07 +05:30
ashilkn
55b4ce8326 [mob][photos] Update flutter version in github workflows 2024-08-27 14:09:27 +05:30
Manav Rathi
8813b0cf1c [meta] Run PRs lint checks for pull requests from external forks
Currently, for PRs opened by external contributors, the various lint checks
don't run (sometimes causing code that fails basic lint checks to be committed
to main).

From my current understanding (I find the docs around this confusing), we need
to instead use the "pull_request" target. Refs:

* https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#pull_request
* https://securitylab.github.com/resources/github-actions-preventing-pwn-requests/

Note that even then, we will need a manual step to approve running the lints for
first time contributors. Which is fine, at least we'll see the option, unlike
right now where they just can't be run until the code hits main.
2024-08-26 21:50:04 +05:30
ashilkn
54a0a09251 Update auth github workflows to use flutter 3.24.0 2024-08-21 15:14:41 +05:30