Skip to main content
3 votes

GitHub Actions Runner execute commands with sudo GitHub Actions

airtower-luna from GitHub community answered it here and it worked for me Answer pasted below: The command in your workflow file is not the same as the one in your sudoers file, sudo doesn’t know they ...
Takasur's user avatar
  • 161
2 votes
Accepted

decode base64 Github Secrets

This is guaranteed to always fail: run: | [ "$GITHUB_REF_NAME" = Cypress-reconfigure ] && echo $STAGING_ENV_FILE | base64 --decode > .env [ "$...
BMitch's user avatar
  • 3,410
2 votes
Accepted

Github Actions Last Build API

List workflow runs would be the equivalent API endpoint in Github Actions: GET /repos/:owner/:repo/actions/workflows/:workflow_id/runs You can use the status query parameter e.g. to filter for ...
Max's user avatar
  • 158
2 votes
Accepted

How does Github Actions work with docker containers?

Yes your understanding is correct. The full documentation is here https://docs.github.com/en/actions/using-jobs/running-jobs-in-a-container
Levi's user avatar
  • 1,064
2 votes

What are the differences between Azure DevOps (Pipelines) and GitHub Actions?

Different between Azure DevOps versus GitHub Actions: Azure Pipelines supports a legacy classic editor, which lets you define your CI configuration in a GUI editor instead of creating the pipeline ...
Vy Do's user avatar
  • 175
2 votes

What would be the best approach or tool to deploy one-off SQL scripts?

The absolute first change in your process I would make is to add the files to source control. Maintaining the scripts in version control is probably your highest priority as this should be your main ...
Preston Martin's user avatar
  • 3,278
1 vote
Accepted

Does Github Actions support anything but Ubuntu?

No Github only supports Ubuntu as of 2024 (and osx, and windows). You can see the list of supported runners for public repositories private repositories You can find the source code for the runners ...
Evan Carroll's user avatar
  • 2,591
1 vote

Github Actions: How to export a variable from within Docker and reuse across steps?

Solution explained in https://docs.github.com/en/github-ae@latest/actions/learn-github-actions/variables We can use GITHUB_ENV for variables within the job, or GITHUB_OUTPUT for variables explicitly ...
psisis's user avatar
  • 21
1 vote

How many deployment environments are appropriate for SPA + API architecture?

My first thought when I see two components that depend on each other during a deployment - often the app and the database - I try to come up with a way to decouple them. If you can deploy your UI and ...
Fenton's user avatar
  • 343
1 vote

CI statistics for GitHub actions

You can get what you need using the gh cli and awk, like this: gh run list | awk -F'\t' 'NR>1 {print $(NF-2), $(NF-1)}' where: NR>1 remove the header $(NF-2) and $(NF-1) refer to the second (-...
benCat's user avatar
  • 71
1 vote

CI statistics for GitHub actions

Nothing like this exists in GitHub unfortunately. Insights will give you PR and merge statistics, but not build times or such. This would have to be implemented with a 3rd party tool or self-built.
Preston Martin's user avatar
  • 3,278
1 vote

"An unknown error occurred" when authenticating between GitHub Actions and AWS using OIDC

The issue was caused by not removing the space after repo: in the IAM Identity Provider Trust relationships' trust policy line that I had copied from the blog "token.actions....
Edward Moffett's user avatar
1 vote

User-level secrets in GitHub Actions

I haven't seen this, since the GHA only has the person who triggered and commits context available. For testing, it's better to have a user assigned to this purposes and then store its secrets in the ...
Alberto Castillo G's user avatar
1 vote

How to upload a file as user input in Github Actions workflow?

It would be easier to store secrets in either secrets or specific environments in the repo: Secrets: https://github.com/**account_name**/**repo_name**/settings/secrets/actions Environments: https://...
Terry Bonds's user avatar
1 vote
Accepted

Can we run github actions inside a docker container?

There are two aspects: can github actions run containers? Can github actions run container like jenkins To answer the former, by default Github actions do run in containers. From the docs: Your ...
Bruce Becker's user avatar
  • 3,743
1 vote

Run a dev server in CI pipeline

The pipeline is configured correctly, you were just missing one piece of the puzzle called service containers. Basically, the service containers also known as sidecars will run alongside your "...
Totem's user avatar
  • 111
1 vote
Accepted

How do I force Packer to use Azure client secret in GitHub Actions workflow?

The solution was to declare the variables in the json template used by Packer build command.🙈 Like this: { "variables": { "azure_cd": "{{env `azure_cd`}}", ...
Pascal's user avatar
  • 11
1 vote

Why should I tag a commit to create a release?

A changelog is handy as one will see what changes reside in a certain release. A couple of months ago one of my tools was not working anymore. By consulting the Changelog it was possible to find the ...
030's user avatar
  • 13.3k
1 vote
Accepted

How to configure EC2 inbound rules for GitHub Actions deploy

If the running is aware of it's IP, you could run github action step which takes that as an input var to aws cli or Terraform to update the security group applied to the instance you're targetting, ...
Bruce Becker's user avatar
  • 3,743
1 vote

pypa/gh-action-pypi-publish token value 'does not start with "pypi-"'

In my case the issue was that I added secrets as "environment secret" rather than "repository secret", leaving the latter empty.
kuropan's user avatar
  • 111
1 vote
Accepted

pypa/gh-action-pypi-publish token value 'does not start with "pypi-"'

I was only wrapping my PyPI secret token in one pair of curly brackets! Two are required, like ${{ secrets.nmdc_schema_pypi_token }}
Mark Miller's user avatar
1 vote

Our code is behind a firewall and we don't want to put source code in cloud. Are there any good CI/CD using local agents for Azure/Github actions

Azure DevOps also has a solution called Azure DevOps Server. It allows you to host you source code on-prem, and also build on-prem. Depending on your needs you could store your artifact on-prem or in ...
GetShifting's user avatar
1 vote

How do I prevent a given GitHub Workflow from being launched twice from two almost simultaneous events?

We have similar situations whereby you want the action to do different things based on the files changed within the commit. You could generate a list of files modified within the PR/commit (within ...
cmsmith7's user avatar
1 vote
Accepted

How can I use a buildah script for image generation using GitHub Actions?

Here is what I did, I create a Makefile that includes my own method of image creation, .PHONY: image clean image-release image: image-release image-release: cargo build --release buildah ...
Evan Carroll's user avatar
  • 2,591

Only top scored, non community-wiki answers of a minimum length are eligible