Social.Income.explained.mp4
Social Income is a radically simple solution in the fight against poverty. The global open-source initiative converts donations into an unconditional basic income, which is sent directly to the mobile phones of people living in poverty in the Global South.
Admin Tool | Website | Mobile App | |
---|---|---|---|
Purpose | Make it simple to manage payments, contributors and recipients | Raising donations and inform the public | Make it simple for recipients to manage payments and surveys |
Instructions | Readme | Readme | Readme / Contributing |
Localhost | localhost:3000 / 4000 | localhost:3001 | – |
Staging | staging-admin.socialincome.org | staging.socialincome.org | Testflight / App Distribution |
Production | admin.socialincome.org | socialincome.org | iOS / Android |
Issues | Open issues | Open issues | Open issues |
UI Library | – | Storybook / Figma | – |
-
Choose an issue and leave a comment that you'd like to work on it (upon we assign it to you)
↗
All issues↗
Help wanted↗
Good first issues -
Setup the basic development environment
↓
Setup -
Clone the repo and work on it
↓
Developing -
Create a PR and wait for it to be reviewed
-
If approved, the PR will be merged into the
main
branch, first on the staging and subsequently on production↓
Deployments
Frontend developers: You can also develop UI components with Tailwind CSS and shadcn/ui independent of the website (Readme / Contributing). The components are all collected in our Storybook and Figma file.
We are mainly leveraging the following tools:
- Firestore for data management
- Firebase Authentication for user management
- Firebase Hosting to serve static content, such as the admin app
- Vercel for website hosting
- Firebase Functions to run backend code in a serverless framework
- Firebase Storage to store documents and other files
- Firebase Emulators for the local dev environment
We use mise-en-place to run the local development environment. Please familiarize yourself with the documentation to understand how to set up and use it.
If you have mise installed, you can run the following command to set up the local development environment:
mise install
and then start the local development environment with:
mise dev
To run the tools separately either use the scripts in the package.json file or run the mise tasks, e.g. both these commands start the admin tool:
mise run admin
npm run admin:serve
No production credentials are needed for local development.
Developer Login for Admin Tool
Localhost Admin Tool Login (Link)
Choose "Sign in with Google" and select the listed "Admin (admin@socialincome.org)" account.
Staging Admin Tool Login (Link)
Contact the dev team (dev@socialincome.org) which can assign you access rights to login.
Production Admin Tool Login (Link)
Only selected people from the SI team have access.
Developer Login for Website (Donor Dashboard)
Localhost Website Login (Link)
- Go to the Login page and select
- Sign in with username test@test.org and password test@test.org.
Staging Website Login (Link)
To create a donor account in the staging environment, proceed through the donation process. Utilize the Stripe test card (4242 4242 4242 4242) for making a test donation.
Production Website Login (Link)
Only actual donors have accounts and can log in. Consider making a (symbolic) donation to create your own account.
An initial dataset is imported into the Firebase emulators at startup.
You have the flexibility to add, delete, or modify data directly through
your Admin Tool or the
Firestore Admin Interface
locally. After making any changes, you can export the updated data to
the seed folder using the command npm run firebase:export
.
- Read the storyblok documentation.
- Set the values
STORYBLOK_PREVIEW_TOKEN
andSTORYBLOK_PREVIEW_SECRET
to the env.development. You can find theSTORYBLOK_PREVIEW_TOKEN
at the storyblok_token and theSTORYBLOK_PREVIEW_SECRET
at the VISUAL_EDITOR in thepreview-url
. - (optional-step)
npm run dev:ssl-proxy
, this is needed if you want to preview the changes on the storyblok live editor for the local environment.
We are using Prettier to format the code:
npm run format-code
.
Staging: PRs merged into main
are automatically deployed to
staging (Admin Tool /
Website) upon core developer
approval. Check Github Actions for details.
Experienced contributors can deploy directly
without approval.
Production: Deployments are made by core developers via GitHub releases.
Naming Convention
Use the format "release-YYYY-MM-DD" for naming releases (example:
release-2021-02-27
). For multiple releases on the same day, append a
suffix such as ".2", ".3", and so forth, to distinguish them (example:
release-2021-02-27.2
).
We have a function which triggers hourly backups of our production firestore database. The exports are saved to the social-income-prod bucket with a retention period of 30 days.
Restore Database
To restore the database you can import the most recent folder directly from the social-income-prod bucket.
You can report an issue or request a feature on our issue page. If you want to report a vulnareablity please refer to our security policy.
Troubleshooting Development
Problem: Added or amended translations do not appear in the localhost preview.
Solution: Remove the website/.next
folder, which is automatically
generated, then re-execute npm run website:serve
.
Become a contributor of Social Income (tax-deductible in Switzerland).
Become a sponsor and help ensure the development of open source software for more equality and less poverty. Donations through the GitHub Sponsor program are used for building a strong developer community.
Social Income is a non-profit association (CHE-289.611.695) based in Zurich, Switzerland. Connect with us X, Insta, LinkedIn, Facebook or by email.
We believe that transparency builds trust and trust builds solidarity. This is why we disclose our finances to the public.
Open Source isn’t an exclusive club. It’s made by people just like you. These individuals, amongst many others, have made significant contributions to Social Income's success:
We receive in-kind donations from Google Nonprofit, GitHub, Codemagic, Linktree, Twilio, Algolia, JetBrains, Storyblok, 1Password, Mux, Sentry and Lineto. Our tools also leverage other open-source technologies, including solutions like FireCMS, Storybook and Tailwind CSS.
This project is licensed under MIT, with the exception of the Unica77 font, which is exclusively licensed to Social Income.