Rename http auth, update readme

This commit is contained in:
Balazs Perlaki-Horvath 2024-12-15 20:45:54 +01:00
parent 2457877fe2
commit b9febbd6be
6 changed files with 45 additions and 5 deletions

View File

@ -60,7 +60,7 @@ jobs:
- name: Generate project based on tag
env:
DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION: ${{ secrets.DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION }}
HTTP_BASIC_ACCESS_AUTHENTICATION: ${{ secrets.HTTP_BASIC_ACCESS_AUTHENTICATION }}
run:
|
# move the custom files under the same folder as the kiwix repo

View File

@ -61,7 +61,7 @@ jobs:
- name: Generate project based on tag
env:
DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION: ${{ secrets.DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION }}
HTTP_BASIC_ACCESS_AUTHENTICATION: ${{ secrets.HTTP_BASIC_ACCESS_AUTHENTICATION }}
run:
|
# move the custom files under the same folder as the kiwix repo

View File

@ -87,6 +87,46 @@ Where the:
Note: Both iOS and macOS applications are created from the same source code and are versioned and released together.
# Release from an external Apple Account (non kiwix)
In order to use a different Apple Account for your app, further setup is required.
**PLEASE NOTE: the values for the below keys contain secret values, do not send them publicly to GitHub tickets, or any publicly available space.** These secrets need to be sent over e-mail or via other Private Message solution.
## Create the Application on Apple Developer
You need to create a new App on your Apple Developer account, please tick both iOS and macOS when creating it. Take note of the bundleID you pick for your application, that should be put into info.json (see above). Additionally each team (Apple Developer Account) has a unique development team ID, this should be also put into the info.json file for your brand.
A dedicated GitHub environment will be created for you, where your secrets will be kept.
## Certificates
These certificates need to be created one by one [under your Apple Developer Account](https://developer.apple.com/account/resources/certificates/list):
- "Apple Development - Sign development versions of your iOS, iPadOS, macOS, tvOS, watchOS, and visionOS apps."
- "Apple Distribution - Sign your iOS, iPadOS, macOS, tvOS, watchOS, and visionOS apps for release testing using Ad Hoc distribution or for submission to App Store Connect."
- "Developer ID Application - This certificate is used to code sign your app for distribution outside of the Mac App Store Connect."
### Download and export your certificates:
- The automated build process, require your certifates to be in .p12 format. Once you have created the above certificates, you can download them to a mac, and export them using the .p12 format, following [Apple guide on this](https://help.apple.com/xcode/mac/current/#/dev154b28f09).
- During export you need to set a password protecting the certificate itself, please take note of it.
From the above process you will have 3 certificates exported to .p12 format, 3 passwords. These need to be set on GitHub environment by us, under the keys:
- APPLE_DEVELOPMENT_SIGNING_CERTIFICATE
- APPLE_DEVELOPMENT_SIGNING_P12_PASSWORD
- APPLE_DISTRIBUTION_SIGNING_CERTIFICATE
- APPLE_DISTRIBUTION_SIGNING_P12_PASSWORD
- APPLE_DEVELOPMENT_SIGNING_IDENTITY
### Set up Apple store authentication
In order to automatically build and upload the builds to the App store the following also need to be set up under the GitHub environment:
- APPLE_STORE_AUTH_KEY
- APPLE_STORE_AUTH_KEY_ID
- APPLE_STORE_AUTH_KEY_ISSUER_ID
### Sign your apps for distribution outside of the App Store:
In order to do so, we will need the following values as well:
- APPLE_SIGNING_TEAM
- APPLE_SIGNING_ALTOOL_USERNAME
- APPLE_SIGNING_ALTOOL_PASSWORD
## ZIM file behind http authentication (optional)
- HTTP_BASIC_ACCESS_AUTHENTICATION - (optional) this is the http basic authentication username:password, it is required to be set if the ZIM file download is behind authentication. This has to use the format: "my_user:secret_password".
License
-------

View File

@ -8,6 +8,6 @@
"settings_default_external_link_to": "alwaysLoad",
"settings_show_external_link_option": false,
"settings_show_search_snippet": false,
"zim_auth": "DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION",
"zim_auth": "HTTP_BASIC_ACCESS_AUTHENTICATION",
"zim_url": "https://www.dwds.de/kiwix/f/dwds_de_dictionary_nopic_2024-11-15.zim"
}

View File

@ -8,7 +8,7 @@
"settings_default_external_link_to": "alwaysLoad",
"settings_show_search_snippet": false,
"settings_show_external_link_option": false,
"zim_auth": "DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION",
"zim_auth": "HTTP_BASIC_ACCESS_AUTHENTICATION",
"zim_url": "https://www.dwds.de/kiwix/f/dwds_de_dictionary_nopic_2023-12-15.zim",
"build_number": 3
}

View File

@ -69,7 +69,7 @@ class InfoParserTest(unittest.TestCase):
def test_auth_value(self):
self.assertEqual(self.parser.download_auth(), os.getenv(
"DWDS_HTTP_BASIC_ACCESS_AUTHENTICATION"))
"HTTP_BASIC_ACCESS_AUTHENTICATION"))
if __name__ == '__main__':