{"id":13585889,"url":"https://github.com/ayoubeddafali/sind","last_synced_at":"2025-04-07T10:32:05.187Z","repository":{"id":104632649,"uuid":"292921069","full_name":"ayoubeddafali/sind","owner":"ayoubeddafali","description":"Minimal framework for web automation using selenium \u0026 pyautogui","archived":false,"fork":false,"pushed_at":"2021-02-27T20:21:26.000Z","size":7647,"stargazers_count":17,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-02-14T21:18:25.611Z","etag":null,"topics":["automation","chrome","docker","dockerfile","pyautogui","selenium"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ayoubeddafali.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-09-04T18:35:50.000Z","updated_at":"2024-08-01T16:31:50.198Z","dependencies_parsed_at":"2023-03-22T19:45:52.743Z","dependency_job_id":null,"html_url":"https://github.com/ayoubeddafali/sind","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayoubeddafali%2Fsind","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayoubeddafali%2Fsind/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayoubeddafali%2Fsind/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayoubeddafali%2Fsind/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ayoubeddafali","download_url":"https://codeload.github.com/ayoubeddafali/sind/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247636897,"owners_count":20971024,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","chrome","docker","dockerfile","pyautogui","selenium"],"created_at":"2024-08-01T15:05:12.392Z","updated_at":"2025-04-07T10:32:03.760Z","avatar_url":"https://github.com/ayoubeddafali.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cimg  src=\"./images/logo.png\" width=\"300\" height=\"300\" /\u003e\n\u003c/div\u003e\n\n\u003cbr\u003e\n\n\u003e A minimal framework to automate web Actions/Plans, and run them in a containerized fashion. \n\n![build status](https://github.com/ayoubeddafali/sind/workflows/Python%20application/badge.svg)\n\n### Structure\n\nThe project is composed of : \n\n - **drivers/** : Contains the webdrivers for both chrome \u0026 firefox. \n - **tests/** : Where you puts your tests. \n - **downloads/** : An optional folder in case your selenium script will need to download/save something for the web. \n - **Dockerfile.chrome** : Dockerfile with necessary prerequisite for chrome browser.\n - **main.py** : Entry file.\n - **Pipefile** : Dev Packages. \n - **plan.py** : Example plan file. \n - **start.sh** : bash script used as entrypoint for the docker image.\n\n### Example Scenario\n\nYou will find in the current structure an example plan in the `plan.py` file. \n\nYou can start and override the file directly, or create your custom plans in separate files. \n\nDon't forget to import your plan in the `main.py` file. \n\n```python\nfrom plan import ExecutionPlan\n..\n..\n..\n\nexecutionPlan = ExecutionPlan(browser=driver, display=display, login=LOGIN, password=PASSWORD)\nexecutionPlan.run(URL)\n```\n\n### Development\n\nWhile on development phase, you might need to run the plan locally and see your selenium script. \n\nMake sure to have the following points marked. \n\n1. Install some tools :\n\n```bash\n$ sudo apt-get install -y xvfb xserver-xephyr\n$ sudo apt-get install scrot -y\n```\n\n2. Setup environment \u0026 dependencies\n\n```bash\n$ pip install pipenv \n$ make shell\n$ make install\n```\n\n3. Run your app : \n\n```\n$ make run\n```\n\n### Run your tests \n\n```bash\n$ make test\n```\n\n### Production\n\nOnce you've finished writing your scenario, you will then start by building a docker image : \n\n```bash\n$ IMAGE_TAG=custom_image:1.0  make image\n```\n\nAnd run it like : \n\n```bash\n$ docker run custom_image:1.0 \n# Or \n$ docker run -v /tmp/screens:/home/agent/screenshots custom_image:1.0 \n# Or\n$ docker run -v /tmp/screens:/home/agent/screenshots -v /tmp/downloads:/home/agent/screenshots custom_image:1.0 \n# You can also pass environments variables at runtime\n# List can be found on the dockerfile\n```\n\n### Available Tools : \n\n - selenium : Trivial\n - pyautogui : When selenium is no longer enough for slightly complex actions\n - pyscreenshot : To screen the execution state.\n\n\n\u0026copy; 2020, Ayoub Ed-dafali.\n\n[![forthebadge](https://forthebadge.com/images/badges/built-with-love.svg)](https://forthebadge.com)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fayoubeddafali%2Fsind","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fayoubeddafali%2Fsind","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fayoubeddafali%2Fsind/lists"}