{"id":15901608,"url":"https://github.com/axel-op/package-java-agnostic-serverless-function","last_synced_at":"2025-08-24T03:33:30.689Z","repository":{"id":65159005,"uuid":"538126511","full_name":"axel-op/package-java-agnostic-serverless-function","owner":"axel-op","description":"A GitHub Action to package an agnostic serverless function in Java","archived":false,"fork":false,"pushed_at":"2022-12-03T16:53:11.000Z","size":31,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-03-14T16:23:00.026Z","etag":null,"topics":["agnostic-serverless-function","agnostic-to-frameworks","aws-lambda","azure-functions","github-actions","google-cloud-functions","java","maven"],"latest_commit_sha":null,"homepage":"https://github.com/axel-op/agnostic-serverless-functions-java","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/axel-op.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-09-18T13:58:32.000Z","updated_at":"2022-12-03T16:51:41.000Z","dependencies_parsed_at":"2023-01-12T14:31:12.290Z","dependency_job_id":null,"html_url":"https://github.com/axel-op/package-java-agnostic-serverless-function","commit_stats":{"total_commits":22,"total_committers":2,"mean_commits":11.0,"dds":"0.045454545454545414","last_synced_commit":"4c5b068daa8ca2c62d33ff4d57db6d49d9f711f4"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axel-op%2Fpackage-java-agnostic-serverless-function","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axel-op%2Fpackage-java-agnostic-serverless-function/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axel-op%2Fpackage-java-agnostic-serverless-function/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/axel-op%2Fpackage-java-agnostic-serverless-function/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/axel-op","download_url":"https://codeload.github.com/axel-op/package-java-agnostic-serverless-function/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246883447,"owners_count":20849486,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agnostic-serverless-function","agnostic-to-frameworks","aws-lambda","azure-functions","github-actions","google-cloud-functions","java","maven"],"created_at":"2024-10-06T11:05:12.024Z","updated_at":"2025-04-02T19:42:48.728Z","avatar_url":"https://github.com/axel-op.png","language":null,"readme":"# Agnostic Serverless Functions in Java: Package Action\n\nAn [agnostic serverless function](https://github.com/axel-op/agnostic-serverless-functions-java) is a serverless function whose configuration is not linked to a particular FaaS framework.\n\nThis action performs the packaging steps needed before deploying a Java function to a specific FaaS provider.\n\n## Usage\n\n```yml\nname: Example workflow\n\non: push\n\njobs:\n  example-job:\n    \n    env:\n      FAAS_PROVIDER: gcloud # can be: aws, azure, gcloud\n      MAVEN_SERVER_ID: github-packages # this is the id set in pom.xml\n\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions/checkout@v3\n      - name: Set up JDK and Maven settings\n        uses: actions/setup-java@v1\n        with:\n          java-version: 11\n          server-id: ${{ env.MAVEN_SERVER_ID }}\n          server-username: MAVEN_USERNAME\n          server-password: MAVEN_PASSWORD\n      - name: Package\n        env:\n          MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}\n          MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}\n        uses: axel-op/package-java-agnostic-serverless-function@main\n        with:\n          function-name: name-of-your-function\n          faas-provider: ${{ env.FAAS_PROVIDER }}\n        # working-directory: . # required if different from $GITHUB_WORKSPACE\n\n```\n\n### Inputs\n\n- `function-name`: the name of the function that will be deployed.\n- `faas-provider`: the provider the function will be packaged for. Accepted values are: `aws`, `azure`, `gcloud` (more providers to come).\n\n### Outputs\n\n- `deployment-directory`: the absolute path of the directory containing the files to be deployed.\n\n### About Maven settings\n\nBuilding an agnostic function [requires Maven artifacts](https://github.com/axel-op/agnostic-serverless-functions-java#configuration) hosted on GitHub Packages. [This README](https://github.com/axel-op/maven-packages) explains how to add them in the dependencies of your Maven project. To retrieve them during the workflow, [the Maven settings file](https://maven.apache.org/settings.html) must contain your credentials to GitHub Packages.\n\nThe example above uses [`actions/setup-java`](https://github.com/actions/setup-java) to tell Maven to use the environment variables `MAVEN_USERNAME` and `MAVEN_PASSWORD` as credentials. These environment variables are only set during the packaging step.\n\n## Full example\n\nCheck out [this workflow](https://github.com/axel-op/agnostic-serverless-functions-java-example/blob/main/.github/workflows/deployment.yml) for a complete example of a deployment workflow using this action.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faxel-op%2Fpackage-java-agnostic-serverless-function","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faxel-op%2Fpackage-java-agnostic-serverless-function","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faxel-op%2Fpackage-java-agnostic-serverless-function/lists"}