diff --git a/.github/actions/buildresources/action.yaml b/.github/actions/buildresources/action.yaml index 841116b..e8525bd 100644 --- a/.github/actions/buildresources/action.yaml +++ b/.github/actions/buildresources/action.yaml @@ -59,6 +59,6 @@ runs: if: ${{ always() && inputs.jb-save == 'true'}} uses: actions/upload-artifact@v4 with: - name: build-${{ inputs.os }} + name: build-${{ runner.os }} path: book/_build/ diff --git a/.github/workflows/build_website.yaml b/.github/workflows/build_website.yaml index 8217154..31d1610 100644 --- a/.github/workflows/build_website.yaml +++ b/.github/workflows/build_website.yaml @@ -49,4 +49,3 @@ jobs: jb-cache: false publish-to-gh: false jb-save: true - os: ${{ matrix.os }} diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 1e7b4bb..360887f 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -24,7 +24,6 @@ jobs: runs-on: ubuntu-latest environment: name: github-pages - url: ${{ steps.deployment.outputs.page_url }} steps: - name: Checkout repository uses: actions/checkout@v4 diff --git a/.github/workflows/netlifypreview.yaml b/.github/workflows/netlifypreview.yaml index 3f9eea5..de9372e 100644 --- a/.github/workflows/netlifypreview.yaml +++ b/.github/workflows/netlifypreview.yaml @@ -37,9 +37,10 @@ jobs: uses: nwtgck/actions-netlify@v3.0 with: publish-dir: './book/_build/html' - production-deploy: false github-token: ${{ secrets.GITHUB_TOKEN }} deploy-message: "Deploy from GitHub Actions" + enable-github-deployment: false + enable-commit-status: false enable-commit-comment: false enable-pull-request-comment: true overwrites-pull-request-comment: true diff --git a/book/CoC.md b/book/CoC.md index b5e0757..c506457 100644 --- a/book/CoC.md +++ b/book/CoC.md @@ -1,42 +1,39 @@ -# Event Code of Conduct +# Participant Conduct -Guidelines to ensure we offer a hospitable and inclusive event and a list of resources for reporting violations. Although the content is similar, this event Code of Conduct should not be confused with the {{ '[Contributor Covenant Code of Conduct]({url}/{repo}/blob/main/CODE_OF_CONDUCT.md)'.format(url=github_org_url, repo=book_repo) }} governing contributions to this JupyterBook. +We require all participants in the University of Washington (UW) eScience Hackweek program to comply with the [eScience Code of Conduct](https://escience.washington.edu/about/code-of-conduct/) copied below. +Hackweek participants are intentionally diverse across many categories including academic standing, domain field, technical experience, etc., and we expect everyone to respect all perspectives represented. Please also read the [eScience Equity Statement](https://escience.washington.edu/about/equity-statement/). ---- +## Code of Conduct -## Overview +The University of Washington eScience Institute (“eScience”) is dedicated to providing a welcoming, supportive and inclusive environment for all people, regardless of background and identity. We do not tolerate discrimination or harassment based on characteristics that include, but are not limited to gender, gender identity and expression, sexual orientation, marital status, disability, physical appearance, body size, race, age, national origin or religion. Any form of behavior to exclude, intimidate, or cause discomfort is a violation of the Code of Conduct. By participating in this community, participants accept to abide by the eScience Code of Conduct and accept the procedures by which any Code of Conduct incidents are resolved. -The organizers of this event are dedicated to providing a harassment-free learning experience for everyone regardless of gender, gender identity and expression, sexual orientation, disability, physical appearance, body size, race, ethnicity, age or religion. -We do not tolerate harassment of participants in any form. Sexual language and imagery is not appropriate for any event venues in either in-person or virtual form, including the Slack workspace. Participants (including event volunteers and organizers) violating these rules may be sanctioned or expelled from the {{hackweek}} at the discretion of the organizers. +In order to foster a positive and professional learning environment we encourage the following kinds of behaviors on all platforms and during all events, both in-person and online: -## Definition of Harassment +* Use welcoming and inclusive language +* Be respectful of different viewpoints and experiences +* Gracefully provide and accept constructive criticism +* Show courtesy and respect towards other community members Harassment includes, but is not limited to: -* Verbal comments that reinforce social structures of domination related to gender, gender identity and expression, sexual orientation, disability, physical appearance, body size, race, ethnicity, age, religion. -* Sexual images in public spaces +* Written or verbal comments that reinforce social structures of domination related to gender, gender identity and expression, sexual orientation, marital status, disability, physical appearance, body size, race, age, national origin or religion +* Violent threats or language directed against another person +* Sexual language or images in public spaces * Deliberate intimidation, stalking, or following -* Harassing photography or recording -* Sustained disruption of talks or other events -* Inappropriate physical contact -* Unwelcome sexual attention +* Continuing to initiate interaction (including photography or recording) after being asked to stop +* Publication of private communication without consent +* Sustained disruption of talks, events, or communications +* Insults or put downs +* Nonconsensual or unwelcome physical contact * Advocating for, or encouraging, any of the above behavior -## Expectations +Participants asked to stop any harassing behavior are expected to comply immediately. This applies to any eScience events or activities, either online or in-person. Participants violating these rules may be sanctioned or expelled from participation at the discretion of eScience staff. The organizers may take action to redress anything designed to, or with the clear impact of, disrupting the event or making the environment hostile for any participants.  -We expect participants and instructors to act in ways that foster a supportive and welcoming learning community at all event venues and event-related social activities. We expect you to support collaboration and learning while participating in this community of practice. Hackweek organizers may take action to redress anything designed to, or with the clear impact of, disrupting the event or making the environment hostile for any participants (including unintentionally). Participants asked to stop any harassing behavior are expected to comply immediately. Failure to comply may result in the participant being expelled from the event at the discretion of the organizers. +Harassment and other code of conduct violations reduce the value of our programming for everyone. If someone makes you or anyone else feel unsafe or unwelcome, please report it as soon as possible. You can make a report either personally or anonymously. To personally report, contact the eScience executive director, Sarah Stone, at sstone3@uw.edu or another trusted staff member. Anonymous reports can be made [here](https://bit.ly/uwhackweekfeedback). If you are experiencing a problem or issue that needs to be addressed by someone outside the program, you may contact the UW Office of the Ombud at ombuds@uw.edu or 206-543-6028. -## Reporting a violation -Harassment and other code of conduct violations reduce the value of the event for everyone. If someone makes you or anyone else feel unsafe or unwelcome, please report it as soon as possible. +[SafeCampus](https://www.washington.edu/safecampus/) (206-685-7233) is also available at any time to anonymously discuss safety and well-being concerns for yourself and others. SafeCampus is the University of Washington’s violence-prevention and response program, providing resources to UW students, staff, faculty and community members. For more information, visit their [What to Expect](https://www.washington.edu/safecampus/what-to-expect) page. -If you feel comfortable contacting someone associated with our event, you may speak with one of the event organizers in person, send an e-mail to {{ '[`{email}`](mailto:{email})'.format(email=contact_email) }}, or contact an organizer on a private Slack channel. You may also submit an anonymous comment to our {{ '[virtual comment box]({url})'.format(url=anon_reporting_url) }}. +Thank you for helping to make our institute inclusive, welcoming and safe. -If you have experienced or observed harassment, unethical or unprofessional behavior as described above (a violation of this code of conduct) and want to talk to someone not directly associated with our event about it, choose from these specialists below: -* Contact the Office of the Ombud, 206-543-6028, ombuds@uw.edu, [www.uw.edu/ombud](https://www.uw.edu/ombud). For individuals who are uncertain about whether they want to pursue a formal complaint but would like to speak to someone about unethical or unprofessional behavior or some other challenging situations, the Ombud office provides a confidential, informal, and neutral resource for you. They can assist you with determining what, if any, course of action you would like to pursue and to navigate the different resources on campus. -* Speak up about discrimination to the University Complaint Investigation and Resolution Office (UCIRO), 206- 616-2028, uciro@uw.edu. Staff are available if you would like to file a formal complaint regarding discrimination. -* Speak up about sexual misconduct to the Title IX Office, 206-616-5334, tixinv@uw.edu, [link](https://www.washington.edu/compliance/tixio/). Staff are available if you would like to file a formal complaint regarding sexual misconduct. - - -This anti-harassment policy is based on the example policy from the Geek Feminism wiki, created by the Ada Initiative and other volunteers. diff --git a/book/preliminary/git.md b/book/preliminary/git.md index 1904454..0d10d92 100644 --- a/book/preliminary/git.md +++ b/book/preliminary/git.md @@ -30,7 +30,7 @@ Set your username and email address. The email address should be the same as you used to register your GitHub account. ```{attention} -Use your personal name instead of the placeholder `{{hackweek}} Attendee` +Use your personal name instead of the placeholder `Attendee Name` in the below commands. For the email, it should be the address you used to create your GitHub account instead of `attendee@hackweek.com`. Both values need to be surrounded by quotes `"`. @@ -61,7 +61,7 @@ command. The output should look similar to this: ```shell jovyan@jupyter:~$ git config -l -user.name= Attendee Name +user.name=Attendee Name user.email=attendee@hackweek.com credential.helper=store ``` diff --git a/conda/environment.yml b/conda/environment.yml index cdea46d..b35b149 100644 --- a/conda/environment.yml +++ b/conda/environment.yml @@ -27,3 +27,4 @@ dependencies: platforms: - linux-64 - osx-64 + - osx-arm64 diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 0000000..2eb08cb --- /dev/null +++ b/docs/README.md @@ -0,0 +1,7 @@ +# Recommended Additional Configuration + +Some template features require additional GitHub settings. For example, the [netlifypreview.yaml](.github/workflows/netlifypreview.yaml) workflow requires a [netlify account](https://www.netlify.com) and configuring Netlify and GitHub to work together + +[github-setup.md](./github-setup.md): Our recommendations for configuring a GitHub organization and managing secrets for a Hackweek + +[netlify-setup.md](./netlify-setup.md): Documentation on setting up previews of website changes in pull requests with Netlify \ No newline at end of file diff --git a/docs/github-setup.md b/docs/github-setup.md new file mode 100644 index 0000000..04db60f --- /dev/null +++ b/docs/github-setup.md @@ -0,0 +1,27 @@ +# GitHub Setup + +## GitHub Organization + +We recommend that each hackweek creates a [GitHub Organization](https://docs.github.com/en/organizations/collaborating-with-groups-in-organizations/about-organizations) to manage various repositories for an event. This makes organizing teams of users easy and consolidates content such as project work and tutorials for easier discoverability. It also allows managing secrets and making them available to different repositories if necessary. + +## Hackweek Bots + +For NASA-focused hackweeks we created a "bot" user with a Gmail account, GitHub Account https://github.com/hackweek-admin, and NASA Earthdata login (https://urs.earthdata.nasa.gov) to allow GitHub Actions workflows to access NASA Data with a set of credentials that do not belong to any individual. + +## GitHub Actions Secrets + +We can add credentials as ["Organization Secrets"](https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions) and make them available to only select repositories that need them. For example see the screenshots below on giving the `EARTHDATA_PASS` secret to a specific repository + +1. ### Repository secrets are under `Settings` -> `Secrets and variables` + + For example, replace `snowex-hackweek/website-2024` for your repository in the following URL: https://github.com/snowex-hackweek/website-2024/settings/secrets/actions + + **only people with `admin` access to a repository can access these settings** + + ![Repo secrets](./images/github-repo-secrets.png) + +1. ### Select `Manage organization secrets`. + + You can either create a new one, or click the "pencil" icon of an existing one to give access to a new repository + + ![Org Secrets](./images/github-org-secrets-list.png) \ No newline at end of file diff --git a/docs/images/github-org-secrets-list.png b/docs/images/github-org-secrets-list.png new file mode 100644 index 0000000..04902ce Binary files /dev/null and b/docs/images/github-org-secrets-list.png differ diff --git a/docs/images/github-repo-secrets.png b/docs/images/github-repo-secrets.png new file mode 100644 index 0000000..03158f8 Binary files /dev/null and b/docs/images/github-repo-secrets.png differ diff --git a/docs/images/github-repo-secrets2.png b/docs/images/github-repo-secrets2.png new file mode 100644 index 0000000..9487753 Binary files /dev/null and b/docs/images/github-repo-secrets2.png differ diff --git a/docs/images/netlify-addsite.png b/docs/images/netlify-addsite.png new file mode 100644 index 0000000..3a9fcdc Binary files /dev/null and b/docs/images/netlify-addsite.png differ diff --git a/docs/images/netlify-auth-token.png b/docs/images/netlify-auth-token.png new file mode 100644 index 0000000..151ea94 Binary files /dev/null and b/docs/images/netlify-auth-token.png differ diff --git a/docs/images/netlify-install-github-app.png b/docs/images/netlify-install-github-app.png new file mode 100644 index 0000000..4dbf26a Binary files /dev/null and b/docs/images/netlify-install-github-app.png differ diff --git a/docs/images/netlify-link-github.png b/docs/images/netlify-link-github.png new file mode 100644 index 0000000..13c16d7 Binary files /dev/null and b/docs/images/netlify-link-github.png differ diff --git a/docs/images/netlify-repo-access.png b/docs/images/netlify-repo-access.png new file mode 100644 index 0000000..f74237d Binary files /dev/null and b/docs/images/netlify-repo-access.png differ diff --git a/docs/images/netlify-select-org.png b/docs/images/netlify-select-org.png new file mode 100644 index 0000000..ebeac4f Binary files /dev/null and b/docs/images/netlify-select-org.png differ diff --git a/docs/images/netlify-select-repo.png b/docs/images/netlify-select-repo.png new file mode 100644 index 0000000..f29166f Binary files /dev/null and b/docs/images/netlify-select-repo.png differ diff --git a/docs/images/netlify-stop-builds.png b/docs/images/netlify-stop-builds.png new file mode 100644 index 0000000..315dc14 Binary files /dev/null and b/docs/images/netlify-stop-builds.png differ diff --git a/docs/netlify-setup.md b/docs/netlify-setup.md new file mode 100644 index 0000000..3a8fe20 --- /dev/null +++ b/docs/netlify-setup.md @@ -0,0 +1,80 @@ +# Configuring Netlify for pull request previews + +Public websites for hackweeks have content contributed by many different people, and we want to ensure that they are well-formatted and functional at all times. In order to do this, we "preview" changes to a website to confirm it all looks good before merging new content. There are different ways to accomplish this, but we have found that [Netlify](https://www.netlify.com) is free and works well for previews. + +## Link Netlify to a repository + +Netlify organizes websites by "Site" which is tied to a specific GitHub repository. *All preview links created are persistent and public but not indexed by search engines.* If you want to delete them, you can delete the 'Site' from Netlify. Importantly, the Netlify previews are completely decoupled from the main website that is hosted by GitHub Pages, so you do not need to worry about overwriting or losing your main event webpage! + +1. ### Make sure the Netlify App is installed for your organization + + Go to https://github.com/apps/netlify/installations/select_target or visit GitHub Org settings for GitHub Apps (e.g. https://github.com/organizations/snowex-hackweek/settings/installations): + + ![Add Site](./images/netlify-install-github-app.png) + + Under 'Configure' for Netlify you can select which repositories Netlify has access to: + + ![Add Site](./images/netlify-repo-access.png) + +1. ### Log into Netlify and 'Add new site' + + ![Add Site](./images/netlify-addsite.png) + +1. ### Select import an existing project + +image + +1. ### Select deploy project with GitHub + + ![Link GitHub](./images/netlify-link-github.png) + +1. ### Select correct GitHub Organization for website repo + + ![Select org](./images/netlify-select-org.png) + +1. ### Select correct repository based on this template (e.g. website-2024) + + ![Select repo](./images/netlify-select-repo.png) + + For 'Site name' enter something informative like `snowex-website-2024` and click 'Deploy' + +1. ### Disable netlify main deployment + + Important!! We only want to use Netlify for *Previews* so under 'Site Configuration' -> 'Build & Deploy' -> 'Continuous deployment' -> 'Build settings' -> 'Configure' -> select "Stopped Builds" -> Save + (e.g. https://app.netlify.com/sites/snowex-website-2024/configuration/deploys) + + If you do not do this, you will have a public mirror of your website available at your netlify site name (https://snowex-website-2024.netlify.app) + + ![Disable builds](./images/netlify-stop-builds.png) + +1. ### Copy unique NETLIFY_SITE_ID to use in GitHub Actions Workflows + + Copy the "Site ID" token string under "Site Details", it will look something like this "f9235abc-688d-45e4-8f62-5519ghi455j1" + + (e.g. https://app.netlify.com/sites/snowex-website-2024/configuration/general) + +1. ### Create a NETLIFY_AUTH_TOKEN to use in GitHub Actions workflows + + Go to https://app.netlify.com/user/applications and under 'Personal access token' create a new token with optional expiration. It will look something like this `nfp_8abcUxd2ESPs9yEegb3ATSBst13JicvY135s` + + ![Auth token](./images/netlify-auth-token.png) + + +1. ### Add GitHub Action Secrets to your repository + + In the end, a website repository needs to have access to both `NETLIFY_AUTH_TOKEN` and a specific `NETLIFY_SITE_ID` for the preview workflow to function: + + ![Repo secrets final](./images/github-repo-secrets2.png) + + In your website repository, go to 'Settings' -> 'Secrets and variables' -> 'Actions' -> 'New repository secret' . Make one for `NETLIFY_SITE_ID` and `NETLIFY_AUTH_TOKEN` with the codes copied in the previous two steps. + +1. ### Ensure that the workflow has permission to write issue comments + + image + + In your website repository, go to 'Settings' -> 'Actions' -> 'General' and scroll to the section on workflow permissions. Make sure sure that the workflow has read/write permissions. By default, this will be disabled at the organization level, so if the read/write is greyed out, you will need to have a GitHub organization admin change the org level permissions. To do this, go to the GitHub organization then 'Settings' -> 'Actions' -> 'General' and scroll to the section on workflow permissions. + +1. ### Trigger your first deploy + + Edit a file in GitHub, Commit and create a pull-request. Label the pull request 'preview'. You will need to create the 'preview' label the first time. Once you create the PR with label 'preview', the Netlify workflow will be triggers and when finished a link to a preview of the website will appear in the PR comments. + diff --git a/team/README.md b/team/README.md index 39cb9db..1975d3a 100644 --- a/team/README.md +++ b/team/README.md @@ -1,16 +1,21 @@ # The team folder -All members of the organizing team should add themselves to the webpage and -this folder contains a file for each person describing themselves. +All members of the organizing team should add themselves to the webpage. +This folder contains a file for each person describing themselves. ## Adding a new member Follow these steps to add yourself: -* Use the provided 'template.yaml' file and copy the file. -* Create a copy of the 'template.yaml' file and rename the file to your name +* Navigate to the 'landing page' repository for your event. +* Navigate into the 'teams' directory. +* Use the provided 'template.yaml' file. +* Create a copy of the 'template.yaml' file and rename the file to your name. +In the GitHub interface, you can create a new file and copy-paste from the template. +Or, in a local repository you can do this on the command line with ``` cp template.yaml FirstName-LastName.yaml ``` * Open the new file you just created in your favorite editor and fill out the details, replacing the placeholder text. -* Commit the file and open a pull request -* Don't forget to add a reviewer to the pull request so they get notified. +* Commit the file and (if necessary) push your changes to GitHub. +* Open a pull request (PR). +* Don't forget to add a reviewer to the PR so they get notified. \ No newline at end of file