How to list all pages of a github organization - github-pages

I am new to a GitHub Organization, and some of the document/guides is Not on README.md/Wiki/docs, but on GitHub Pages. So
Is there any way to list all available GitHub Pages on this GitHub Organization?
I've tried gh/git CLI, and GitHub GUI, not none of them could achieve it.

A user site or an organisation site would be a repository named <username>.github.io or <organization>.github.io, so that is easy enough to check.
But a project site would be any repository with a 'has_pages' attribute set to true.
That means you can list org repositories, focusing on that attribute, to filter out the ones which does have pages
gh api -H "Accept: application/vnd.github+json" /orgs/ORG/repos --jq '.[].has_pages'

Related

AUTH for AWS using NEXT.js

I am struggling to find good info on setting up auth for a web page. I need it to have three levels of access.
ADMIN, which can control everything i.e. allowing the other levels to exist.
Editor, which can see the posts made in a backend situation. Editors will have to be approved by the ADMIN.
Authors, who can put, read and delete (only their own posts).
I don't want the authors to have to wait to make posts on the site. But Editors and ADMINS need to be approved. I feel that making a separate site for Editors and ADMINS is the solution to this.
Can anyone point me in the right direction concerning this?
Questions I need to be answered:
How Do I set up the three levels?
Is there one login that the ADMIN has to view and approve? I need it to be secure but not CAPTCHA or MFA Secure. I know AWS and Amplify uses Cognito which is fine. I would prefer to not use a Social provider login. Just an email login.
Since this website will require a database (S3 bucket) for the info that will be uploaded by the authors, will the login info be stored in a different database (DynamoDB for instance)?
I want to use Amplify, Next.js, and AWS.
Sites I have been reading and I'm sure have the answer but I am not seeing.
https://docs.amplify.aws/cli/auth/overview/
https://nextjs.org/docs/authentication
https://next-auth.js.org/providers/cognito

GitHub pages defaulting to a randomly generated name instead of <whatever>.github.io

I'm working in a repo I created under an organizational GitHub
When I publish the repo via GitHub pages the URL defaults to a randomly generated string, such as
http(s)://windy-waterfalls-e5r23og9.pages.github.io/
I'd like it to default to http(s)://<username>.github.io/<repository> or http(s)://<organization>.github.io/<repository> so that the URL is explanatory of the repo, and so I don't have to pay/manage my own domain
Is there a way to do this?
This occurs when the gh pages visibility is set to private
According to About subdomains for privately published sites
Privately published sites are available at a different subdomain than publicly published sites. This ensures that your GitHub Pages site is secure from the moment it's published.
We use a unique subdomain for the privately published site to ensure that other repositories in your organization cannot publish content on the same origin as the site
According to Organization-level custom domain not working for internal repository pages #23350
For security reasons, private Pages sites (the ones with a random default hostname that enforce authentication + authorization on access) need to be isolated.
Workarounds
If the info isn't sensitive, you can go to Settings > Set the Visibility to Public
You can still set a custom domain to avoid having a long set of garbled characters in your URL

cannot publish my github page at the correct address

I am trying to set up my personal page on Github.
However, my page is only published at: https://xuxy09.github.io/xuxy09/, while the desired address is https://xuxy09.github.io.
Could you please let me know how to fix this?
Issue addressed. The repository name should be "xuxy09.github.io" instead of "xuxy09".
That is described in "Types of GitHub Pages sites"
To publish a user site, you must create a repository owned by your user account that's named <username>.github.io.
Unless you're using a custom domain, project sites are available at http(s)://<username>.github.io/<repository>
In your case, a repo named xuxy09 is a Project site.
While xuxy09.github.io would be, indeed, a User site.

Cannot view the list of GitHub Repository in Build Trigger settings

The company I belong to sets https://help.github.com/en/github/authenticating-to-github/authenticating-with-saml-single-sign-on .
In this case, if my set up Cloud Build Trigger with my company's G Suite Account, I can display a list of GitHub Repository.
However, even if I want to set a Trigger on a personal GitHub Repository with a gmail.com account, I will get an error trying to get all Organization Repositories.
Is there a workaround for this?

package domain, role and user on sitecore

I am new to sitecore.
I have a question regarding packaging Domain and Roles on sitecore (we are using sitecore 6.3.1).
I am packaging content from our dev box to stage and I would like to transfer the Domain, Roles and user created on dev to stage.
The package designer shows a button called 'Security Accounts'. I added the specific user \ who belong to the specific domain and role.
On installing the package to stage site, it throws an error 'blah domain not found, cannot create user'.
So the question is, do i have to create a domain manually on the stage server before I install the user? or is there a way where I can copy the domain and roles to create the user?
Help much appreciated.
I have discovered that the domains are stored in /App_Config/Security/Domains.config and you can migrate between installations simply by copying or editing this file.
Or you can create the domains manually via the Security Domain tool.
Either way the domain must exist before you can install a package with users or roles.
If your target solution doesn't have the domain the user lives in, you'll have to create it manually. However, the roles can be transferred via package the same way as users. If the user A is in role B, and you don't add role B to the package, there should not be any error - simply the user A won't be a member of the role B on target environment.
I would think the answer Yan comes with would work with domains.
But you might need to have the Domain(s) in a package which you install first, or have it as the first "part" of your package, so it gets installed first.